type casting varchar to int
Started by Hoosain Madhiover 25 years ago2 messagesgeneral
Is it possible to type cast from varchar to int? Postgres backend complains
when I try to do this.
Hoosain Madhi
Switching Engineering
VODACOM CORPORATE PARK
Tel : +27 11 653 5030
Fax : +27 11 653 5941
Re: type casting varchar to int
You can make an intermediate step through text
<colume>::text::int
However, it'll fail if there are any values it cannot
turn into an integer (with an elog) which may not
be what you want.
Stephan Szabo
sszabo@bigpanda.com
On Fri, 8 Sep 2000, Hoosain Madhi wrote:
Show quoted text
Is it possible to type cast from varchar to int? Postgres backend complains
when I try to do this.