[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

[sqr-users] Using parenthesis in a dynamic where cond.



Can anybody tell me how to generate a dynamic where condition in which I need 
to incorporate parenthesis between AND statements? Here's the condition without 
the parenthesis:
LET $DATE_RANGE = 'and A.SHIP_DATE  <=  '''|| $ToDate || '''' || ' AND   
A.SHIP_DATE >=  '''|| $FromDate ||'''' 
 
THis should look like 

select * from ps_zsc_ld_seq A 
where (A.SHIP_DATE >= '01-AUG-05' and A.ADD_DTTM >= '01-AUG-05')
AND (A.SHIP_DATE <= '31-AUG-05' and A.ADD_DTTM <= '31-AUG-05')

Thanks very much.


                
---------------------------------
 Start your day with Yahoo! - make it your home page 

_______________________________________________
sqr-users mailing list
sqr-users@sqrug.org
http://www.sqrug.org/mailman/listinfo/sqr-users