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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Grouping into a new table

Hello,

I have in the moment a "blackout"!

I need help to following problem:

I have a table:

dateCapaClosing 30 Day
2021-12123yes
2021-11124yes
2021-11532no
2021-1136yes
2021-11574yes
2021-1245875no
2021-1288yes
2021-12546yes
2021-12463yes
2021-12364no
2021-124374yes
2021-0847yes
2021-0858yes
2021-08589yes
2021-086964no
2021-08489yes
2021-08499yes

 

FWil_0-1656528884963.png

 

 

 

 

I want to create the followingtable with a DAX function

 

dateClosing 30 Day yesClosing 30 Day no
2021-0851
2021-1131
2021-1252

 

FWil_1-1656528933105.png

 

 

 

Thanks for help

Friedbert

1 ACCEPTED SOLUTION
vapid128
Solution Specialist
Solution Specialist

image.png

Table5 = 
SUMMARIZE(
    Table4,
    Table4[date],
    "Closing 30 Day yes",CALCULATE(COUNTROWS(Table4),FILTER(Table4,Table4[Closing 30 Day]="yes")),
    "Closing 30 Day no",CALCULATE(COUNTROWS(Table4),FILTER(Table4,Table4[Closing 30 Day]="no"))
)

View solution in original post

4 REPLIES 4
Jihwan_Kim
Super User
Super User

Hi,

Please try the below.

It is for creating a new table.

 

Untitled.png

 

New Table = 
GENERATE (
    VALUES ( Data[Date] ),
    {
        ( CALCULATE (
            COUNTROWS (
                FILTER (
                    SELECTCOLUMNS ( Data, "@Closing30dayYes", Data[Closing 30 Day] ),
                    [@Closing30dayYes] = "Yes"
                )
            )
        ), CALCULATE (
            COUNTROWS (
                FILTER (
                    SELECTCOLUMNS ( Data, "@Closing30dayNo", Data[Closing 30 Day] ),
                    [@Closing30dayNo] = "No"
                )
            )
        ) )
    }
)

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.
Anonymous
Not applicable

Thank you very much, it woorks.

vapid128
Solution Specialist
Solution Specialist

image.png

Table5 = 
SUMMARIZE(
    Table4,
    Table4[date],
    "Closing 30 Day yes",CALCULATE(COUNTROWS(Table4),FILTER(Table4,Table4[Closing 30 Day]="yes")),
    "Closing 30 Day no",CALCULATE(COUNTROWS(Table4),FILTER(Table4,Table4[Closing 30 Day]="no"))
)
Anonymous
Not applicable

Thank you very much, it woorks.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

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.