parameter marker [message #766873] |
Fri, 16 December 2011 15:29 |
ADA Messages: 1 Registered: December 2011 |
Junior Member |
|
|
SELECT b.INVOICE_ID, b.SEQUENCE_VALUE, trunc (b.creation_DATE)
FROM pa.painvoices_all b
WHERE b.creation_DATE BETWEEN TO_DATE('2011/12/01','RRRR/MM/DD')
AND TO_DATE('2011/12/05','RRRR/MM/DD')
As a parameter marker (?) to write the SQL query for the condition b.creation_DATE ?
[Updated on: Fri, 16 December 2011 15:31] Report message to a moderator
|
|
|
Re: parameter marker [message #780644 is a reply to message #766873] |
Wed, 18 January 2012 21:06 |
|
So, you're wanting to know how to pass user entered dates as your start and end dates in your query? If so, one way you could do it would be to make your "where" statement something like:
WHERE b.creation_DATE BETWEEN TO_DATE('startDate','RRRR/MM/DD') AND TO_DATE('endDate','RRRR/MM/DD')
And then, in your beforeOpen script of your dataSet, run a replace on your query text to replace your startDate and endDate markers with the actual parameter values. The sample database doesn't use the TO_DATE function, so I can't try the (?) marker in place of the date just like in your query. Have you tried it? Do you get an error? Let me know.
Regards,
Michael
http://www.birt-exchange.org
Michael
Developer Evangelist, Silanis
|
|
|
Powered by
FUDForum. Page generated in 0.03000 seconds