Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Groupby count inside summarize

Hello everyone,
Hope you are all good and safe in this time. I have created a new table (Table 2)based on calculation from Table 1 My table looks like this

Table 1:

IDNOStore_NumberSlow 
AA1S1y
AA1S2n
AA1S3y
AA1S4y
AA1S5n
AA1S6y

 

Table 2:

IDNOStore_NumberAffected by
AA1S2S1
AA1S3S1
AA1S4S1
AA1S4S3
AA1S5S1
AA1S5S3
AA1S5S4
AA1S6S1
AA1S6S3
AA1S6S4

Because of slow offloading at stores other stores get affected and hence a new table needs to be created as shown above showing the problem causing stores .For example : S4 is affected because of slow offloading at s1 and s3 as both these storesd are marked as "y"

Now Im able to Retreive all the Stores that has affecetd the store in study as below with the following code :

CALCULATE(CONCATENATEX(
                   SUMMARIZE(
                             Table2,
                                 Table2[Affected by]
                             ),
                   Table2[Affected by],
               ",",
             TREATAS(VALUES(Table1[Store_Number]),Table2[Store_Number]))

 

I would like the times affected as well such as for example if S4 is under study i would like it to display S1(Times affected), S2(Times Affected) instead of just S1,S2 as code displays .


ANy leads is greatly appreciated _/\_.Thanks

0 REPLIES 0

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.