Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
joshrussin
Creator III
Creator III

How to include data from day before

I am trying to create a formula that will be the equivalent of this.

Selected_Date - (Day_Before_WIP - Current_Processed)

Trying to display the data within this graph

graph help.jpg

This is what the table looks like.

chart1.PNG

10 Replies
vishsaggi
Champion III
Champion III

May be this ?

SelectedDate - (Sum({< Date = { "$(= Date(Date(DateField, 'MM/DD/YYYY') -2) )" } WIP) - Sum(CurrentProcessed))

joshrussin
Creator III
Creator III
Author

I tried this and nothing is coming up

Sum(WIP) - (Sum({< "Date" = { "$(= Date(Date(DateField, 'MM/DD/YYYY') -2) )" } WIP) - Sum(Processed)))

Sorry, to explain the equation a little better, I need the Sum of Today's WIP "WIP" minus the result of

(Yesterday's WIP - Today's Processed)

I need it to show up in the pivot table like above. Thanks

vishsaggi
Champion III
Champion III

Can you share a sample to look into and did you change the datefield with your actual date field name. May be try this?

Sum(WIP) - (Sum({< "Date" = { "$(= Date(Date(Date, 'MM/DD/YYYY') -2) )" } WIP) - Sum(Processed)))

joshrussin
Creator III
Creator III
Author

Here is a sample of what I have. If you go to the sheet there is the pivot table.

this is the correct output, but with hard coded values. I am trying to figure out how to make qlik do the math portion rather than excel.

chart_Help.jpg

vishsaggi
Champion III
Champion III

This is Qlik Sense right? I will have to look into it later.

joshrussin
Creator III
Creator III
Author

Thank you, Yes it is Qlik sense. I appreciate it very much.

vishsaggi
Champion III
Champion III

I have changed the measure expression can you check if the values are coming out correctly?

Attached the qvf file.

joshrussin
Creator III
Creator III
Author

Data is showing, but it is not correct. I don't think it is getting yesterday's data correctly.

If you filter by mechanical inspection - lots

here are the correct results

chart_Help.jpg

vishsaggi
Champion III
Champion III

Is this the same working file you sent me or a different one?