Forum Discussion
Create Table with distinct values and count them
- 4 years ago
Create an inactive relationship from your Date table to the Sale Date column and then you can use USERELATIONSHIP, like
Num sales = CALCULATE( COUNTROWS('Table'), USERELATIONSHIP( 'Date'[Date], 'Table'[Sale date]))
Create a proper Date table, and link the Date column to the Sale Date column in your current table. You can then use columns from the Date table in any visuals and create a measure like COUNTROWS('Products')
Thanks johnt75, I've created a proper calendar table, and already have a relationship with my product A table (to the manufacturing date), and whenever I try to work with standard measures it doesn't count the relevant rows.
i'm trying to get to some sort of a formula similar to count if Date=Sale Date
- johnt754 years agoSuper User
Create an inactive relationship from your Date table to the Sale Date column and then you can use USERELATIONSHIP, like
Num sales = CALCULATE( COUNTROWS('Table'), USERELATIONSHIP( 'Date'[Date], 'Table'[Sale date]))