Forum Discussion
senright1989
9 years agoNew Member
Counting unique values in a column based on numerous values
Hi All, I have searched through this forum for a few hours today and for some reason i couldn't get what i am trying to do to work. I have the table called "Sample". ...
- Anonymous9 years ago
Something like this?
Occurs = VAR PayItem = [Pay Item #] RETURN CALCULATE( countrows('YourTable'), ALL('YourTable'), 'YourTable'[Pay Item #] = PayItem )
kaushikd
9 years agoResolver II
Hi for data refference i have taken your data( #Sample)
what your requirement is can be easily impleamented using a measure.
Step 1. R.click on the table and click New Measure
Step 2. Use this dax to calculate the count of Pay Item Count of Item = Count('Sample'[Pay Item])
Step 3. In the report page drop a table and select Date---Pay Item---Count of Item as the fields.
Please have a look what i have done here.
If this is what you are looking for the please don't forget to mark this as a solution.
--Regards
Kaushik