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: 
rittermd
Master
Master

Formulas Stopped Working

We are running NPrinting Feb 2018 and were on November 2018 QS. 

Under that scenario I had created an NPrinting pixelperfect report with a bunch of formulas in it.  They all worked fine.

We just upgraded to June 2018 QS and for the time being are still on Feb 2018 NPrinting.

All of the formulas stopped working and I just get a '-' where data used to display.

Here is an example of one of the formulas.  They are all similar to this.

avg( {<CalendarDate={"$(=date#(today()-1))"}>}($(vTotalRouteTime))*24)

Something changed with the upgrade.  But I have yet to figure it out.  At least that is what I think happened.

8 Replies
rubenmarin

Hi Mark, I woluld try to use the same expression directly in Sense to confirm vTotalRouteTime values and date formats, maybe "$(=date#(today()-1))" is returning dates in a different format that CalendarDate stores dates.

rittermd
Master
Master
Author

That was my thinking also.  CalendarDate is a datetime field.  But as far as I know it always has been.  I"ll keep digging.

rubenmarin

You can also try setting the format with Date(), (not Date#())

"$(=date(today()-1), 'DD/MM/YYYY')"


If it's a timestamp use timestamp() instead of date().


Also, if you leave the expression without label it will show the value converted in $-expansion, wich will be used to look sometimes I found that an equal sign at start was needed:

"=$(=date(today()-1), 'DD/MM/YYYY')"


There can be also the option of using single quotes to look for exact value:

CalendarDate={'$(=date#(today()-1))'}

rittermd
Master
Master
Author

So this version now returns data.  However, it is as if it is ignoring the Set Analysis or the Set Analysis is not true.  It is returning a value for the entire data set of 9.78.  When I filter in the app for yesterdays data this calculation comes back as 9.13.

avg( {<CalendarDate={"=$(=Date#(today()-1))"}>}($(vTotalRouteTime))*24)

Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

That basicly means your set analysis is not working.

The above formula "CalendarDate={"=$(=Date#(today()-1))"}" does not make any sense!!!

  • Today() function returns date already in numeric/date format!!
  • Applying Date# function on it is pointless since it is searching for TEXT to convert it to date/number
  • My suggestion would be to:
    • check how CalendarDate is created in script
    • When created is it Flooredusing Floor function to make sure that timestamp is removed
    • is there Date function applied on it? If yes - what is the formatting of it, is it custom or default from system variables?
    • you can try using "CalendarDate={"$(=Date(Today()-1))"} in your set analysis


Mark, can you just explain first where do you have a problem - Is this a NPrinitng problem or Qlik Sense?

  1. I would start my investigation from the fact that QlikSense June was bringing in quite a big change in how objects are working. I have seen issues where all extensions stopped working etc..Therefore i would not link NPrinitng Feb2018 with Qlik Sense 2018 as it might not be ready for those changes. This is just my pure thinking and is not backed up by any knowledge if it supposed to work together or not....
  2. Second - i would make sure first that all my expressions first work properly in Qlik Sense, once this is done i would refresh metadata and move to nprinitng

cheers


Lech

--------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.

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.
Ruggero_Piccoli
Support
Support

Hi,

I agree with lech_miszkiewicz‌ and I wuold to suggest also to upgrade Qlik NPrinting to latest vestion to benefit of all solved bugs.

Best Regards,

Ruggero

---------------------------------------------

When applicable please mark the appropriate replies as CORRECT https://community.qlik.com/docs/DOC-14806. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.



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.
rittermd
Master
Master
Author

The issue is only in NPrinting.  The QS app is still working correctly.

We actually did upgrade to June 2018 for NPrinting and saw the same issue.  So we backed down to Feb 2018 thinking the issue was upgrading NPrinting. 

But that was not the issue as it still did not work.

Now to complicate things I have not looked at this report for months.  It is not in Production so no user input if something was wrong.   So this could have stopped working prior to upgrading Qlik Sense.

Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

I also noticed that you use variable instead of field or expression. What happens when you use proper field/expression name instead of variable "($(vTotalRouteTime)"

It is possible that your variable is not evaluated properly when in NPrinting!!!

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.