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: 
RheaQv12
Creator
Creator

filter failing

 

Hi

Can someone please ppoint where I am going wrong.. I have a QVW file and an NPrint Excel template is setup for the daily and it is working fine. We were working on the same kind of setup but for the last weekend but for some reason it is failing.. attached the error log .. we have 2 separate qvw files and 2 separate connections in nprint and different filters

 

the only difference Is the filter setup...

for the last weekend I have used date(WeekEnd(Today(),-1,6)',MM/DD/YYYY') 

can some one please look at the error and suggest what could be wrong.. attached error log

 

Labels (2)
1 Solution

Accepted Solutions
Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

I am quite sure your issue sits in wrong filter:

read this topic (also check other filter topics on my blog):

https://nprintingadventures.com/2019/02/15/the-pitfalls-of-nprinting-filters-part-1-dates-and-duals/

 

in short: - date filter is numerical value (hence DATE() function should not be used when creating a filter. Additionally using WeekEnd function you are creting a TimeStamp with the hour:minute and a second 23:59:59.... This is standard QlikView/QlikSense  knowledge though.

https://help.qlik.com/en-US/sense/November2019/Subsystems/Hub/Content/Sense_Hub/Scripting/DateAndTim...

 

the way a would debug it is:

  • find the way how the field you are trying to filter on is created in QlikView script
  • if it is a date field only i would make sure there is alsofloor function used to remove timestamp from it
  • then in NPrinitng i would use Floor(WeekEnd(Today(),-1,6))

thanks 

Lech

 

cheers Lech, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful to the problem.

View solution in original post

4 Replies
Ruggero_Piccoli
Support
Support

Hi,

There are not attachments. Please add also screenshots of the Task Executions page and the template and filter setups.

Best Regards,

Ruggero



Best Regards,
Ruggero
---------------------------------------------
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads with a LIKE if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads with LIKEs if you feel additional info is useful to others.
RheaQv12
Creator
Creator
Author

Hi Ruggero,

added all screenshots into one zip file..thanks a lot

Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

I am quite sure your issue sits in wrong filter:

read this topic (also check other filter topics on my blog):

https://nprintingadventures.com/2019/02/15/the-pitfalls-of-nprinting-filters-part-1-dates-and-duals/

 

in short: - date filter is numerical value (hence DATE() function should not be used when creating a filter. Additionally using WeekEnd function you are creting a TimeStamp with the hour:minute and a second 23:59:59.... This is standard QlikView/QlikSense  knowledge though.

https://help.qlik.com/en-US/sense/November2019/Subsystems/Hub/Content/Sense_Hub/Scripting/DateAndTim...

 

the way a would debug it is:

  • find the way how the field you are trying to filter on is created in QlikView script
  • if it is a date field only i would make sure there is alsofloor function used to remove timestamp from it
  • then in NPrinitng i would use Floor(WeekEnd(Today(),-1,6))

thanks 

Lech

 

cheers Lech, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful to the problem.
RheaQv12
Creator
Creator
Author

Thank you Lech,

Really appreciate your help. I used date and floor combined it is working fine - This is working fine

 

DATE(Floor(WEEKEND(Today(),-1,6)), 'MM/DD/YYYY')