Using method in SQL statement

Tim James tjames1 at bigpond.net.au
Wed Nov 19 11:08:30 CST 2003


Is it possible to use a method field in a sql statement if the method 
(margin is its name) is calculated as follows

round((1-(costprice/(recretail/1.1)))*100,2)

where recretail and costprice are double fields and method is defined 
as double also

I know I can use method such as Upper(surname) in sql search but are 
there limitations on the use of calculated methods

I can display the method field using an sql statement but apparently 
not use it  as follows

select margin from stock where margin > 25

TIA

Tim James



More information about the Valentina mailing list