All,
First let me say I'm not a used to working with Crystal Reports. I have so far been able to create basic formulas getting the results I need. But for this issue I need to consult you expertise.
I need some quidance how to create a formula for a specific date range within specific time windows. I'm not sure whether I need 2 (just dates) or 4 (dates and times) parameters. But the concept it is. A parameter field is set asking for a date range.
I only need results for data between the dates entered, between the hours of 7pm to 6:30am (Monday to Friday) or possibly using time parameter fields, and 24 hours a day on Saturday's and Sunday's. I'm assuming that due to split days the time will have to be a military range from 19:00 to 24:00, and 00:00 to 06:30 ???
Here's the basic crystal formula I've been tinkering with (not even tackling the weekend 24 hour issue yet..but can't figure out how to create correctly.
{PWDCounter.ResetDate} in
datetime({?Start Date}, time(19,0,0)) to
datetime({?End Date}, time(23,59,59)) and
{PWDCounter.ResetDate} in
datetime({?Start Date}, time(0,0,0)) to
datetime({?End Date}, time(6,30,00))
But I still keep getting 3pm dates.
Any help or guidance would be great !
Thanks in advance,
Brad
First let me say I'm not a used to working with Crystal Reports. I have so far been able to create basic formulas getting the results I need. But for this issue I need to consult you expertise.
I need some quidance how to create a formula for a specific date range within specific time windows. I'm not sure whether I need 2 (just dates) or 4 (dates and times) parameters. But the concept it is. A parameter field is set asking for a date range.
I only need results for data between the dates entered, between the hours of 7pm to 6:30am (Monday to Friday) or possibly using time parameter fields, and 24 hours a day on Saturday's and Sunday's. I'm assuming that due to split days the time will have to be a military range from 19:00 to 24:00, and 00:00 to 06:30 ???
Here's the basic crystal formula I've been tinkering with (not even tackling the weekend 24 hour issue yet..but can't figure out how to create correctly.
{PWDCounter.ResetDate} in
datetime({?Start Date}, time(19,0,0)) to
datetime({?End Date}, time(23,59,59)) and
{PWDCounter.ResetDate} in
datetime({?Start Date}, time(0,0,0)) to
datetime({?End Date}, time(6,30,00))
But I still keep getting 3pm dates.
Any help or guidance would be great !
Thanks in advance,
Brad