Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi experts
I have the following statement giving me entries of the last month:
LOAD *, stunden_1w*stdsatz_alt1W as X_1w;
Load
jobnr,
stunden as stunden_1w,
stdsatz_alt as stdsatz_alt1W
resident Stunden where datum > Date(AddMonths(Today(),-1));
How can I get only values from last weeg?
Best
Jan
LOAD *, stunden_1w*stdsatz_alt1W as X_1w;
Load
jobnr,
stunden as stunden_1w,
stdsatz_alt as stdsatz_alt1W
resident Stunden where datum > Weekstart(Today(),-1);
LOAD *, stunden_1w*stdsatz_alt1W as X_1w;
Load
jobnr,
stunden as stunden_1w,
stdsatz_alt as stdsatz_alt1W
resident Stunden where datum > Weekstart(Today(),-1);
Hi Jan,
where week(datum) = week(today())-1
BR
M
Or, (if you want only last week data)
resident Stunden where datum >= Weekstart(Today(),-1) and datum <Weekstart(Today());
Edit: corrected
Indeed, but I think there is perhaps a mistake in your syntax
resident Stunden where datum >= Weekstart(Today(),-1) and datum < Weekstart(Today());
Like this, year check will fail.
Sorry man, of course, you are right...