hi chandan,

ojb does not explicitely support database-functions like nvl etc.
but you can use function in the expressions of a criteria:

        Criteria crit = new Criteria();
        crit.addEqualTo("upper(productGroup.groupName)", "LIQUORS");
        Query q = QueryFactory.newQuery(Article.class, crit);

the name of the function will be passed to the database without any translation.

for further examples see org.apache.ojb.broker.QueryTest.

hth
jakob

Chandan AHUJA schrieb:
Hello ,
         I am new to OJB , and I have following query .
In OJB , using the "Criteria" class we can define the where clause .
I would like to know , in OJB how can we manipulate the "fields to be selected"  in the 
"select clause" .
To be more precise how can we use functions like "nvl" and "decode" if we use  
OJB  .


Regards , Chandan .







---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to