Hello,
Yes I would like a user to enter a date range and a team id in a parameter pop up.
In the system that I am querying we have floating employee numbers. These numbers are used by agency staff that are hired on a casual basis. In order to view the correct timesheet details for the employee ID I am querying I need to ensure the date range is set for the same period in 3 tables being:
1. Employee history table (gives me the name of employee assigned to floating badge number within the specified date range)
2. Employee team table (aligns the badge number to a team number) and
3. Work Details table (the period the employee has worked)
Tables 2 and 3 will be where my parameters are pointing to.
The employee may/may not work all days within the fortnight. For example the employee may only work 6 days out of 14. The query would only return payment details for the 6 days actually worked.
I have written my script in SQL and get the correct results when I run it using DBVizulizer - the problem is that my script specifies the same date range for the three tables mentioned above, i.e:
and EMPHIST_START_DATE <= to_date('20090105','yyyymmdd') and EMPHIST_END_DATE >= to_date('20090106','yyyymmdd')
and et.EMPT_START_DATE <= to_date('20090105','yyyymmdd') and et.EMPT_END_DATE >= to_date('20090106','yyyymmdd')
and ws.WRKS_WORK_DATE >= to_date('20090105','yyyymmdd') and WS.WRKS_WORK_DATE <= to_date('20090106','yyyymmdd')
When moving the script to crystal reports I only want to prompt the user for the date range once and not 3 times as the date range for each of the 3 tables will always be the same
Hope this helps you to understand it a little better
Regards,
Despina