Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello.
Is there any way to get only previous month data from data I get from attached qvw? Now I get all data but I want to filtering only previous month data. I need to get those previous month values to Nprint report.
Br.
Timo
May be change this to
LET v.nrp_starttime = TimeStamp(MonthStart(Today(), -1), 'MM.DD.YYYY hh:mm:ss');
LET v.nrp_endtime = TimeStamp(MonthStart(Today()), 'MM.DD.YYYY hh:mm:ss');
This will pull you just the month of Dec 2016 when we are in Jan 2017. When Feb begins, the above should bring you Jan 2017. Is this what you want?
You want to restrict the data in the script?
Should I change something in here?
// Folder for output QVDs use
LET vL.QVDPath = 'C:\Users\tka\Desktop\QVD_Generator';
// Starttime parameter for data loads, current day -4 months
LET v.nrp_starttime = timestamp(AddMonths(today(), -4), 'MM.DD.YYYY hh:mm:ss');
// Endtime parameter for data loads, timestamp of current moment
LET v.nrp_endtime = timestamp(now(), 'MM.DD.YYYY hh:mm:ss');
// Interval parameter
LET v.nrp_interval = 2001;
First, create a datamodel without sync keys.
should this be dynamic so it will always show previous month? if so create variables which hold this info then use the variable in a where statment.
If you want a Object from Your qvw to be present in Nprinting, then build separate Objects inside GUI With set analysis and previous month in your Expression.
Let vPreviousMonthStart = =monthstart(AddMonths(today(),-1)) ; will hold 2016-12-01
Let vPreviousMonthEnd =monthend(AddMonths(today(),-1)) ; will hold 2016-12-31
May be change this to
LET v.nrp_starttime = TimeStamp(MonthStart(Today(), -1), 'MM.DD.YYYY hh:mm:ss');
LET v.nrp_endtime = TimeStamp(MonthStart(Today()), 'MM.DD.YYYY hh:mm:ss');
This will pull you just the month of Dec 2016 when we are in Jan 2017. When Feb begins, the above should bring you Jan 2017. Is this what you want?