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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
mccollough
Helper I
Helper I

Merge queries with WHERE condition

Hi Everyone!

 

I want to add a column to a table via power query with something analogous to a WHERE clause.

 

Here's a simplified version of what I'm trying to do:


Take the [TASK] from the 'Schedule' Table Where [INCLUDE] = 1

mccollough_0-1636584517380.png


Add the activities into my 'Fact Table' which looks like this

mccollough_3-1636584629490.png


To yield my 'Goal' table which should ideally look like this

mccollough_4-1636584694375.png


Thank you SO MUCH for your continued assistance!

 

 

 

 

1 ACCEPTED SOLUTION
AlexisOlson
Super User
Super User

One way to do this would be to add a custom column (all values = 1) to the Fact Table and then do a merge matching columns DATE, NAME, and Custom with DATE, ASIGNEE, and INCLUDE.

 

The other way would be to merge Fact Table with Schedule after filtering the latter for INCLUDE = 1.

View solution in original post

1 REPLY 1
AlexisOlson
Super User
Super User

One way to do this would be to add a custom column (all values = 1) to the Fact Table and then do a merge matching columns DATE, NAME, and Custom with DATE, ASIGNEE, and INCLUDE.

 

The other way would be to merge Fact Table with Schedule after filtering the latter for INCLUDE = 1.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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