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: 
ch_riadh
Partner - Creator II
Partner - Creator II

Nprinting Condition Task

Hi,

I have a table with 4 Fields:

1- Brand

2- Product

3- Date

4- Stock

i want to create Condition task in nprinting 18 Nov, when the stock of any product from any branch on any date = 0,

Send me a report details (Brand, Product and Date).

Thank you

 

1 Solution

Accepted Solutions
Ruggero_Piccoli
Support
Support

Hi,

If it is a Qlik Sense usage case I suggest you to post it in Qlik Sense community, it will be easier to find an expert that could help you. You could also search there if there are similar questions with related solutions.

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.

View solution in original post

23 Replies
Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

read documentation first to understand how conditions work.

https://help.qlik.com/en-US/nprinting/June2019/Content/NPrinting/ReportsDevelopment/Conditions.htm

then depending on your datasource  (QlikView or Qlik Sense) you can use chart table in qlik to create condition object.

If you have something else in mind please provide detailed information regarding setup, report and what you want to report in form of mockup so we have something to work with.

From your question it is not clear whether you actually need a condition or filter

 

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.
ch_riadh
Partner - Creator II
Partner - Creator II
Author

I'm using qliksense with nprinting 18

for example after reload data today morning 

The stock for brand A of product X on  21/10/2019 become 0.
so i need to receive an email with the brand, product and date for that 0.

 

 

Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

Ok then, build the table in Qlik Sense to show only 0 values and use it as a condition (chart has values) to run report and as a source to show which brand, product and date it is for. Obviously this will very much depend on how you pull data. Does your 0 stock actually contain value 0 or it has no associated value (hence you assume it is 0)

If you want real examle share some sample qvf app so i can build on top of it.

cheers

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.
ch_riadh
Partner - Creator II
Partner - Creator II
Author

please find the excel file. nprinting should send a report with this info: Nike short 21/10/2019
ch_riadh
Partner - Creator II
Partner - Creator II
Author

when no stock available it shows 0.

Ruggero_Piccoli
Support
Support

Hi,

Note also that Qlik NPrinting publish tasks can be triggered only on a time bases or via APIs. There are not events driven executions.

So, after creating the condition, you need to schedule the publish task at an adequate interval of time. It will be run on time bases and, if the condition will be met, the reports will be created.

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.
Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

So,

As i said before - how you built your report depends mainly  on your data model. Given the data you have provided you can simply built an object in Qlik Sense which will be your condition chart as well as your report source. Note that i specifically asked how you know that there is 0 stock and if this is a record with 0 value or zero as result of calculation which returns 0 due to lack of associated values).

See sample qvf based on your data source. You need to use this object as condition (Chart has values) and use it to build your report template. 

Then schedule your NPrinting distribution task to be triggered right after your qlik sense finishes reload. You can use API to do this or set regular time based trigger. About API and task chaining you can read here: https://nprintingadventures.wordpress.com/2019/04/08/nprinting-api-qlik-rest-subroutines/

In this task setup condition "Chart has values" and use this chart as condition true/false indicator.

If you have different data model then you need to attach your qvf  file with actual data model. You can scramble data if you need.

cheers

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.
ch_riadh
Partner - Creator II
Partner - Creator II
Author

I use the same qvf you sent to me, and create a condition chat has value then send me mail.
it works fine when there is a stock with 0.

but when i try to add stock to my data. (all products have a stock), and run the task. i still recieve the report with

 

Lech_Miszkiewicz
Partner Ambassador/MVP
Partner Ambassador/MVP

You need to build your expression in qlik sense stock to only show 0 values which i did by using set analysis in my example. Without your data model i will not be able to help

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.