Friends, I need help on below selection critieria in DB2.
Below where clause works fine, but only If I pass my paramter in DATE or DATE TIME format. I wan to give my end user an option to select by Month Year format May2009 instead of 05/23/2009 or so.
Below selection criteria gives me data for last 12 months.
WHERE DATE(ADDED_DT) >= ((DATE({?Report_Date}) - Day(DATE({?Report_Date})) day)+1 day) - 12 month
AND DATE(ADDED_DT) <= (((DATE({?Report_Date}) - Day(DATE({?Report_Date})) day)+1 day) + 1 month) - 1 day
ANy help on how to get that?
Thanks a ton,
V
Below where clause works fine, but only If I pass my paramter in DATE or DATE TIME format. I wan to give my end user an option to select by Month Year format May2009 instead of 05/23/2009 or so.
Below selection criteria gives me data for last 12 months.
WHERE DATE(ADDED_DT) >= ((DATE({?Report_Date}) - Day(DATE({?Report_Date})) day)+1 day) - 12 month
AND DATE(ADDED_DT) <= (((DATE({?Report_Date}) - Day(DATE({?Report_Date})) day)+1 day) + 1 month) - 1 day
ANy help on how to get that?
Thanks a ton,
V