Skip to main content

Hi everybody,

I'm dealing with a simple fidelity program, consisting of some gift cards which have a issue date and a redemption date. The data structure can be reduced to a three column table, consisting of: a card_id (integer), a issue_date (date) and a redeem_date (date). I would like to be able to count, in the same worksheet, the number of cards which have been issued in a specific range of dates, and compare it with the number of cards which have been redeemed in a different time range; for example: number of cards issued in March 2023 (regardless of whether and when they have been redeemed) vs. number of cards redeemed in May 2023 (regardless of when they have been issued). I need to compare the two values because I need to understand how some underlying campaigns are affecting the card redemption behaviour.

 

So I put both issue_date and redeem_date in the filter shelf, and then I created a LOD variable:

 

{FIXED redeem_date: COUNT(card_id)}

 

to count the redeemed cards regardless of the date range set in the filter for issue_date, but the count keeps considering the range set for issue_date. Same thing for the issued card, I created a different LOD variable:

 

{FIXED issue_date: COUNT(card_id)}

 

but I have the same problem, the results depend on the filter range in redeem_date.

 

Neither issue_date nor redeem_date are context variables, so in my understanding the LOD should be computed before the filtering, but it doesn't seem to work. Any suggestions?

 

Thanks for your support!

1 answer
0/9000