• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User


  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to count purchases per customer that happened outside their subscription time?


New Member
Hello Community!

Im fairly new with DAX, and I am dying to get help with this problem!

I am trying to find out:

1. Distinct count of the customers who purchased Product A, OUTSIDE their subscription time.
2. Count of the purchases (Product A) they made OUTSIDE their subscription time

My data model is very simple:

Customer table (relation 1 - * w/ CustomerID) Sales table (relation * - 1 w/Date) Date Table
Customer table (relation 1 - * w/ CustomerID) Subscriptions table

One customer can have two different subscriptions on and off (SubscriptionA, SubscriptionB), which have starting date and ending date. Some are still active and they dont have an ending date.
At any time they can also make purchases (Product A) and Im interested to find out only those which have been made outside these subscription times. Note, that some customers have never been subscribers, only bought Product A. I need these as well.

Hope I was clear with me explanation and someone has time to help with this