Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to change data type when query?

Status
Not open for further replies.

011179

Programmer
Mar 14, 2002
11
0
0
HK
Dear all,

I want to chnage a VARCHAR column into decimal when query.
e.g. create table sample {id VARCAHR(10), value VARCHAR(10))

How can I query the table for value > 40 ?

Thanks!
 
Cast the Varchar to a decimal. For example

select * from fcm00.ic_umatrix
where decimal(umat_keypart1) > 100

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top