I'm trying to convert a var char to an int. I tried a couple methods
described in the documentation, but can't seem to get it to work. Any
thoughts?
In this example, the field my_id is character varying(16):
rs=# insert into table2
rs=# select my_Id::INT
rs=# from table1;
ERROR: Cannot cast type character to integer
rs=#
rs=# insert into table2
rs=# select CASE(my_Id as integer)
rs=# from table1;
ERROR: Cannot cast type character to integer
Any help or links to appropriate documentation appreciated!
--Rick