unique
3 TopicsAlternative to countuniqueif in dax?
My issue you is I have a data table with information saying did a customer buy a product in their first appointment yes it no, the issue is if they buy multiple products it's on multiple lines. I was able to do count unique and base it around customer Id but I can't seem to get round it. (First week of BI)565Views0likes1CommentCount Unique values between a date range
Hey, Had to share this as i've been trying to figure it out for a week now. Finaly got it. So the intention of the below is to add a column in that defines if the row is between the start data and end date, adding a "Yes/No" where true or false. It then filters the table on "Yes" and counts the unique values in a specific coulmn. Where i have used this is to count the tickets raised last month and then compare to the tickets raised the previous month to show a specific increase or decrease in ticket numbers. This took me ages to figure out, hopefully helps someone else! Unique Count = VAR StartDate = EOMONTH(TODAY(),-2)+1 VAR EndDate = EOMONTH(TODAY(),-1) RETURN CALCULATE( DISTINCTCOUNT(Table1[Refference]), Filter( ADDCOLUMNS( Table1, "Last Month", IF(Table1[CLOSE_TIME_Month_Year] >= StartDate && Table1[Table1] <= EndDate, "Yes", "No")),[Last Month] = "Yes"))3.3KViews0likes0CommentsCumulative upto in Dax
Hello, I hope my query doesn't sound funny but I am trying to create a progress chart for the car usage per sequence ( trip ). Here is an example of how the table looks like and the last column is the result I am trying to generate using Dax. Sequence Car type Hours/Sequence 1 Toyota 5 2 Toyota 9 3 Toyota 1 4 Toyota 3 1 Ford 19 2 Ford 7 3 Ford 4 4 Ford 6 1 GMC 10 2 GMC 1 3 GMC 16 4 GMC 5 1 Nissan 7 2 Nissan 0 3 Nissan 3 4 Nissan 1 And the additional generated column using DAX should look like this. Cumulative Hours upto this sequence 5 14 15 18 19 26 30 36 10 11 27 32 7 7 10 11 Do you think its possible to create a Dax loop to distinguish between different car types and calculate the sum of hours up to each sequence.1.3KViews0likes3Comments