Thirumoorthy Bhuvneswari wrote:
> I gave the query as the follows:
> 'insert into tableB select
> (cr_amt::float8),(dr_amt::float8) from tableA;'
> It comes with the error,
> 'Cannot cast type 'varchar' to 'float8'.
There is no function defined as converting directly from
varchar to float8. If you are going to be doing this a lot
you could create a conversion function, otherwise just do:
insert into tableB
select cr_amt::text::float8, dr_amt::text::float8
from tableA
--
Peter Gibbs
EmKel Systems