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

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

Reply
MarceloVieira
Helper II
Helper II

[ Doubt about how to have similar result on powerquery ]

Hello everyone, is there a way to have a similar result direct on powerquery?

 

 

 

FT_OVERDUE_24 = -- THIS IS A CALCULATED TABLE
FILTER(
    ALL( FT_OVERDUE ),
    VAR YEARMONTH_OVERDUE = FT_OVERDUE[YEARMONTH_SEQUENTIAL_OVER]
    RETURN
        FT_OVERDUE[YEARMONTH_SEQUENTIAL_OVER] = YEARMONTH_OVERDUE &&
        FT_OVERDUE[YEARMONTH_SEQUENTIAL_DUE] >= YEARMONTH_OVERDUE - 23 &&
        FT_OVERDUE[YEARMONTH_SEQUENTIAL_DUE] <= YEARMONTH_OVERDUE
)

 

 

This image is on aggregated level. The fact table is on a client granularity.

MarceloVieira_0-1708605342841.png

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @MarceloVieira ,

 

Please follow these steps:

Based on your description, I created the data:

vkaiyuemsft_0-1708677275268.png

1.Create custom columns in the power query editor and write expressions:

if

[due] >= [over] - 23 and [due] <= [over]

then

"1"

else

"0"

             

vkaiyuemsft_1-1708677275271.png

2.Filter the new column, only retain the value of "1" data.

vkaiyuemsft_2-1708677351933.png

3.After getting the desired data, delete the newly created custom column.

vkaiyuemsft_3-1708677351935.png

4.If you want to group the YEARMONTH_SEQUENTIAL_OVER column, you can refer to the documentation: How to GROUP BY or summarize rows - Power Query | Microsoft Learn.

 

If your Current Period does not refer to this, please clarify in a follow-up reply.

 

Best Regards,

Clara Gong

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

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @MarceloVieira ,

 

Please follow these steps:

Based on your description, I created the data:

vkaiyuemsft_0-1708677275268.png

1.Create custom columns in the power query editor and write expressions:

if

[due] >= [over] - 23 and [due] <= [over]

then

"1"

else

"0"

             

vkaiyuemsft_1-1708677275271.png

2.Filter the new column, only retain the value of "1" data.

vkaiyuemsft_2-1708677351933.png

3.After getting the desired data, delete the newly created custom column.

vkaiyuemsft_3-1708677351935.png

4.If you want to group the YEARMONTH_SEQUENTIAL_OVER column, you can refer to the documentation: How to GROUP BY or summarize rows - Power Query | Microsoft Learn.

 

If your Current Period does not refer to this, please clarify in a follow-up reply.

 

Best Regards,

Clara Gong

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

Thks @Anonymous 

 

The solution works very well!!! Really thks for the help!!

MarceloVieira_0-1708694956972.png

 

Helpful resources

Announcements
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.

Top Solution Authors