Bennie47250
Programmer
Using version 7.0
Have a report with 3 sub reports. The main report and one sub report uses the time period of MonthtoDate to select the records. Another sub report uses YeartoDate. And the last sub uses LastfullWeek.
The date field in the database is always a Sunday. And on Monday of each week we enter data for the quantity produced the prior week. Then sometime between that week on or before on Thursday the report will be ran.
The sub-report that selects records based on the LastfullWeek will always be OK as the last full week is always the last full week.
The sub-reports that use YeartoDate and MonthtoDate will be incorrect as the reports could be ran anywhere between the 1st and 10th of any month to report on the prior month or year data but the report will pull the current month or year data.
How can I properly condition for this issue?
I don’t think I can use something like “if Day (CurrentDate) <7
then {table.DateField} in LastFullMonth
else {table.DateField} in MonthToDate”
As in some months, if the report was ran on the 7th, it should pull the MonthToDate data.
I also have the same issue with the YearToDate.
Appreciate your help in resolving this.
Thanks
Bennie
PS I was unable to search for the archive for similar postings as the search was down when I posted this.
Have a report with 3 sub reports. The main report and one sub report uses the time period of MonthtoDate to select the records. Another sub report uses YeartoDate. And the last sub uses LastfullWeek.
The date field in the database is always a Sunday. And on Monday of each week we enter data for the quantity produced the prior week. Then sometime between that week on or before on Thursday the report will be ran.
The sub-report that selects records based on the LastfullWeek will always be OK as the last full week is always the last full week.
The sub-reports that use YeartoDate and MonthtoDate will be incorrect as the reports could be ran anywhere between the 1st and 10th of any month to report on the prior month or year data but the report will pull the current month or year data.
How can I properly condition for this issue?
I don’t think I can use something like “if Day (CurrentDate) <7
then {table.DateField} in LastFullMonth
else {table.DateField} in MonthToDate”
As in some months, if the report was ran on the 7th, it should pull the MonthToDate data.
I also have the same issue with the YearToDate.
Appreciate your help in resolving this.
Thanks
Bennie
PS I was unable to search for the archive for similar postings as the search was down when I posted this.