Reply
jackypatel
Helper I
Helper I
Partially syndicated - Outbound

Unique date wise unique Product Count & Accepted Rejected Count

My Database name is "PDI DATA"&  i required Unique date wise unique names count & Accepted, rejected Count too. E.g. 27-03-2021 has "HM-12.5A-LM-ACC-NS" count is 1 and Accepted Count 1 & 27-03-2021 has "12.5C-FDB-ACC" also count is 1and Accepted Count 1. And at the end i need Grand total of counts

 

Inspection DateProductResult
27-03-2021HM-12.5A-LM-ACC-NSAccepted
27-03-2021HM-12.5B-LM-ACC-NSAccepted
27-03-202112.5C-FDB-ACCAccepted
27-03-2021LTT8-20Accepted
25-03-2021CLR400000-A2Rejected
26-03-2021LD200686-E2Accepted
26-03-2021LD200686-E2Accepted
26-03-2021LD200686-E2Accepted
26-03-2021LD200686-E2Accepted
25-03-2021LDRR24-CDLRejected
25-03-2021LDRR24-CDLRejected
25-03-2021LL725003-D1Accepted
25-03-2021LL725003-D1Accepted
25-03-2021LL725003-D1Accepted
25-03-2021LL725003-D1Accepted
25-03-2021LL725003-D1Accepted
25-03-2021LL725003-D1Accepted
25-03-2021LL725003-D1Accepted
25-03-2021LDLRC-20PRO-CDLAccepted
25-03-2021LT8-20-865-2Accepted
25-03-2021LT8-20-865-2Accepted
25-03-2021LT8-20-865-2Accepted
25-03-2021LT8-20-865-2Accepted
25-03-2021LT8-20-865-2Accepted
25-03-2021LT8-20-865-2Accepted
25-03-2021LT8-20-865-2Accepted

 

1 ACCEPTED SOLUTION
ERD
Community Champion
Community Champion

Syndicated - Outbound

Hi @jackypatel , you can try these measures:

names = DISTINCTCOUNT('PDI DATA'[Product])
accepted = 
VAR _t =
    SUMMARIZE (
        'PDI DATA',
        'PDI DATA'[Inspection Date],
        'PDI DATA'[Product],
        'PDI DATA'[Result]
    )
VAR _accepted = FILTER ( _t, [Result] = "Accepted" )
RETURN
    COUNTX ( _accepted, [Result] )

ERD_0-1699435738604.png

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. Appreciate your Kudos.

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

View solution in original post

3 REPLIES 3
ERD
Community Champion
Community Champion

Syndicated - Outbound

Hi @jackypatel , you can try these measures:

names = DISTINCTCOUNT('PDI DATA'[Product])
accepted = 
VAR _t =
    SUMMARIZE (
        'PDI DATA',
        'PDI DATA'[Inspection Date],
        'PDI DATA'[Product],
        'PDI DATA'[Result]
    )
VAR _accepted = FILTER ( _t, [Result] = "Accepted" )
RETURN
    COUNTX ( _accepted, [Result] )

ERD_0-1699435738604.png

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. Appreciate your Kudos.

Check out my latest demo report in the data story gallery.

Stand with Ukraine!


Here are official ways you can support Ukraine financially (accounts with multiple currencies):
1) Support the Armed Forces of Ukraine: https://bank.gov.ua/ua/about/support-the-armed-forces
2) Come Back Alive foundation: https://www.comebackalive.in.ua/

Thank you!

Syndicated - Outbound thanx for the help
Ahmedx
Super User
Super User

Syndicated - Outbound

Is this what you are looking for?

Sample PBIX file attached

avatar user

Helpful resources

Announcements
March PBI video - carousel

Power BI Monthly Update - March 2025

Check out the March 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors (Last Month)
Top Kudoed Authors (Last Month)