Can we change the data type of a column from integer to float?

Yes, we can change the data type with dmSQL tool or DBATool.

Using dmSQL

The syntax is as follows:

dmSQL> ALTER TABLE table_name MODIFY column_name TYPE TO FLOAT;

Example: The data type of the column salary will be modified to float.

dmSQL> ALTER TABLE t1 MODIFY salary TYPE TO FLOAT;

Using DBATool

  1. From the Object menu, choose Table.

  2. In the Table dialog box, click the "+" beside Column to take you to the Add/Modify dialog box.

  3. Change the data type of the column you are interested in to FLOAT.

  4. Click the button OK

Copyright 1999-2001 CASEMaker Inc. All rights reserved.
Comments or questions about our web site? Please write the webmaster.
Terms and Conditions | User Privacy Statement