hii..I have proplem of converting datatype from decimal to float to show it in view
from table:

create table st_fees(s_no int(4) primary key,s_name varchar(50),
reg_fs decimal(5,2),study_fs decimal(8,2),curr int(1));

and my view creation code is

create view sum_fs as select s_no ,s_name,reg_fs+study_fs as fees,curr from st_fees;

the data type of fees in view is decimal...i like to convert it to float
without changing the origin datatype in table...

can any one help me ....thanks...

Have a look at the CAST() function.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.