casting varchar to numeric - Mailing list pgsql-sql

From Alex K.
Subject casting varchar to numeric
Date
Msg-id 9ganbr$1pdt$1@news.tht.net
Whole thread Raw
List pgsql-sql
Is there any way to cast a varchar value to numeric?

I just found out that neither an implicit nor an explicit cast is permitted
when trying to convert from varchar to numeric, but I need to move the
values from that varchar field (which are all numeric characters, by the
way) into a numeric field.  I'd prefer doing this inside Postgres, as
opposed to scripting it using PERL or something...

Thanks for any helpful advice (helpful advice does NOT include 'You should
have just created a numeric field in the first place').

=)

Alex K.




pgsql-sql by date:

Previous
From: Stephan Szabo
Date:
Subject: Re: possible to lock a single row in table?
Next
From: Najm Hashmi
Date:
Subject: Extracting date from epoche