How to set FilterHilim to LastweekStart + x amount of days - RMS report
I'd like to make it so that whenever I open up employees timeclock .qrp report for the week... that upon opening the report it will auto set the date ranges to last Sunday through Saturday.
Currently I have it filter last Sunday to this Sunday.
Disclaimer: I don't know anything about RMS, other than what I've just read in some search results.
Looking at this old question here on EE, there doesn't seem to be a special name for "end of last week". Or, at least, there apparently wasn't one back then.
I guess one option might be to move the selection criteria into SelCriteria, as described in that post. That way you have more control over the dates.
But if you can add another filter, how about this?
Add a filter where FilterLoLim and FilterHilim are both "<WeekStart>", and set FilterNegated to True. I am _guessing_ that setting FilterNegated to True reverses the test. The idea is that your original filter includes dates through the start of this week, but then the second filter excludes the start of this week.
I don't know about FilterConnector. AND seems the obvious choice, but it may depend on where this new filter is positioned.
James
antman1437
ASKER
mlmcc I'm using RMS reports or crystal reports.
Appreciate the answer James. Trying FilterNegated did not work for me received an error.
As for the information in the other post...I don't know enough code to change the SelCriteria to what I'm trying to accomplish from scratch:
"([Transaction].Time >= DATEADD(month, - 1, CONVERT(datetime, CONVERT(varchar(8), GETDATE(), 120) + '01', 120))) AND ([Transaction].Time < CONVERT(datetime,
CONVERT(varchar(8), GETDATE(), 120) + '01', 120))"
I tried what the post said in removing all filters and then copying that info inside Selcriteria to see if it would work first. Got an error reading report file at "line #19 CONVERT(varchar(9),GETDATE(), 120)+'01',120))"
I'm still lost, hoping a kind soul is able to help me.
mlmcc