Total Pageviews

Search This Blog

Friday, January 25, 2008

Complex query expressions

Filter the records on customer form based on Group or Currency

In init() method of Custtable datasource, put the following code:

CustTable_ds.query().dataSourceNo(1).addRange(fieldnum(Custtable,custgroup)).value(strFmt('((CustGroup=="%1") (Currency=="%2"))',queryvalue("50"),queryvalue("EUR")));

In the value part, we can have OR expression i.e. ((CustGroup=="%1") (Currency=="%2"))
and then the actual values supplied at the end.

No comments: