From: Alex K. <alex@freeview.com>
To: pgsql-sql@postgresql.org
Subject: casting varchar to numeric
Date: Thu, 14 Jun 2001 09:09:02 -0700
Message-ID: <9ganbr$1pdt$1@news.tht.net> (raw)
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.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: alex@freeview.com
Subject: Re: casting varchar to numeric
In-Reply-To: <9ganbr$1pdt$1@news.tht.net>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox