date range problam

To discuss Oracle Forms & Reports related technical issues.
Post Reply
mufti_sb
Posts: 4
Joined: Thu Apr 13, 2006 1:56 am
Location: Pakistan

date range problam

Post by mufti_sb »

in a report i need to show all dates from range
1. 1 ~ 15
2. 15 to last date of the month

note start date and end date is taken dynamically through report paramets

Oracle Certified Professional
System Analist , D.B.A
admin
Posts: 2063
Joined: Fri Mar 31, 2006 12:59 am
Location: Pakistan
Contact:

Post by admin »

You can use lexical to build where query and on parameter selection you should select option 1 or option 2. Now in the pre report trigger you have to do like,

if option 1
v_query := between 1 and 15;
else
v_query := between 16 and last_day(sysdate);
end if

Here is the use of last_day example,

SQL> select last_day(to_date('15/02/2006')), last_day(sysdate) from dual;

LAST_DAY(T LAST_DAY(S
---------- ----------
28/02/2006 30/04/2006

if still issue not resolved then let us know.
Post Reply

Who is online

Users browsing this forum: No registered users and 9 guests