I am in a major problem...
Earlier we have created one column as smallint.
Now we have been asked to convert it to boolean.
I fire following statement ....
alter table user modify(is_consignor boolean);
This gives me error message....
9633: ALTER TABLE can not modify column (is_consignor) type.
Need a cast from the current type to the new type.
At present their are no values in this columns.
In fact I have made them all "null".
alter table <u table> add bcol boolean;
update <u table> set bcol=<some cast from old column>;
alter table <u table> drop <old column>;
4 u plesure ))
Thanks for the solution you have provided...
But problem is that if I create another column after dropping first one the syntax which programmers has written will fell. Because the new column will be added at the last position of the table.
When I tried using dbaccess utility , it dosen't have boolean data type.
Originally posted by Bhushan_sawant
What is the data_type I should select from dbaccess utility. Because I couldn't find "boolean" data type in the list.
A very easier way to do is get a unload of your table first, then take a schema of the table using dbschema and store it in a file, make changes to that file. now go to dbaccess, drop that table and run this script and then load the data.