Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
cliff_clayman
Creator II
Creator II

How to create a straight table with flagged fields

This is a little difficult to explain, but I will try my best to articulate what I am looking for.  I am looking to filter my results in a straight table to determine if a person has made a transaction within the last 3 months and the last 6 months.  I have a field called Period that needs to be evaluated to determine that.  I've attached a sample QVW file that will make a lot more sense once you look at it.  There is also a straight table that contains the data that is summed for all Periods.  So, the current Period value is P9.  I also created a variable that has that in it.  If a person has Charges for Periods 1-9, then I do not wish to see them in the table.  If they have a charge in P1 and then no further charges, I would like to see a flag in the 3 month and 6 month field in the table. If they have charges in P1-P5, then I just want to see a flag in the 3 month field.  Here is a screenshot that might make more sense...

EmployeeLast Period3 Month6 MonthsTotal Charges
JOE SMITHP1xx$510.72
BOB JOHNSONP2xx$109.05
THOMAS DODDP3xx$645.88
ALEX RIVASP4x$713.64
CHRIS COLLINSP5x$1,000.42

Let me know if there s any additional information I can provide.

15 Replies
sinanozdemir
Specialist III
Specialist III

Hey Cliff,

Just a small edit:

Capture.PNG

Please see the new file.

Thanks

cliff_clayman
Creator II
Creator II
Author

Not quite.  For example, A HERNANDEZ ALBARRAN shouldn't be in the result set.  The current period is P9 and they made a purchase in P8, so that person should not show up in the list.  Only those with no transactions in the last 3 months or greater should show up.  Also, ALEX LOPEZ should have an 'X' in 6 months as the last transaction occurred in P1.

cliff_clayman
Creator II
Creator II
Author

ALEX LOPEZ is now correct.  I would like to see an'X' in 3 months and 6 months if the last transaction occurred 6 months or more.  However, AARON JOEL BITTERMAN should only have an 'X' in 3 months and anyone with a last period of P8 or P7 should not be displayed.

sinanozdemir
Specialist III
Specialist III

Alright, take 2:

Capture.PNG

Hope this works

cliff_clayman
Creator II
Creator II
Author

That looks correct!  The only thing I would change is using the Period for the calculation and not date.

sinanozdemir
Specialist III
Specialist III

Cool.

I am glad it worked.