Skip to main content
Announcements
Defect acknowledgement with Nprinting Engine May 2022 SR2, please READ HERE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Date filters in nPrinting 17

Hi,

I am stuck with the filtering functionality at nprinting 17.

What I need to do is to send the last 30 days from a report based on a date field.

I have used evaluate value to do that, but is not working and it is sending all dates.

Help is appreciated.

Screenshot_38.png

Thanks

1 Solution

Accepted Solutions
aaron_ppmc
Partner - Contributor III
Partner - Contributor III

Hy Santiago,

=date(today()-30) is not a range. it is just the date 30 day's before today

i prefer to flag the Dates in load Skript of your app- like if(REPORT_DATE >=date(today()-30),1,0) as ShowLast30Days, then you can use this as Filter in Nprinting.

ShowLast30Days 1

br

View solution in original post

5 Replies
aaron_ppmc
Partner - Contributor III
Partner - Contributor III

hy,

the result of today()-30 is a number not a date, try "=date(today()-30)"

best regards

Not applicable
Author

Thanks, Aaron but did not work.

  • First, if I apply the filter I do not receive the email. Which is weird.
  • Second, when I receive the email after removing the filter the data is not filtered out for the last 30 days.

Any suggestion?

aaron_ppmc
Partner - Contributor III
Partner - Contributor III

Hy Santiago,

=date(today()-30) is not a range. it is just the date 30 day's before today

i prefer to flag the Dates in load Skript of your app- like if(REPORT_DATE >=date(today()-30),1,0) as ShowLast30Days, then you can use this as Filter in Nprinting.

ShowLast30Days 1

br

Not applicable
Author

That made the work Aaron,

Many thanks

mkelemen
Creator III
Creator III

Hi,

unfortunately I do not have NP17 to test it but in 16 this works:

"=REPORT_DATE >= Date(Today()-30)"

The evaluate checkbox needs to be empty for it to work.

Simple ">= Date(Today()-30)" might work in 17 though.

BR,

  Matus