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

The Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.

Reply
newtopbitoo
Frequent Visitor

create flag when other same id in table has value "x"

I have a table containing rows with same Id's.
I want to flag every Id when one of the rows with the same Id when column  y has value x.

I found several options to do it in Dax but would like to have this in power query. Did not find a solution so far.

3 REPLIES 3
noobtopowerbi
Frequent Visitor

I am afraid that my question was not clear.
See screenshot. I want to flag all same id's when one of those id's meets a condition

noobtopowerbi_0-1701944473133.png

 

v-stephen-msft
Community Support
Community Support

Hi @newtopbitoo ,

 

Here's the solution in Power Query:

Sample data:

vstephenmsft_1-1701421604170.png

 

Steps:

1.Group by

vstephenmsft_0-1701421597543.png

vstephenmsft_2-1701421640121.png

vstephenmsft_5-1701421768125.png

 

2.Add a conditional column.

vstephenmsft_4-1701421751065.png

vstephenmsft_6-1701421780027.png

3.Expand the column contains tables and remove the unneeded columns.

vstephenmsft_7-1701421830677.png

vstephenmsft_8-1701421843533.png

Best Regards,

Stephen Tao

 

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

 

PijushRoy
Super User
Super User

@newtopbitoo 
Can you please share screenshot of your data and expected result




Did I answer your question? Mark my post as a solution!
Appreciate your Like/Kudos

Proud to be a Super User!





Helpful resources

Announcements
Feb2025 Sticker Challenge

Join our Community Sticker Challenge 2025

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

Jan NL Carousel

Fabric Community Update - January 2025

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

Top Solution Authors
Top Kudoed Authors