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

Try your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now

Reply
rpiboy_1
Helper V
Helper V

Nesting Queries

Hi all, I've tried this several ways and not getting the result I'm expecting. Here is my scenario:

 

Let us say that I have Query Alpha that the result looks like this.

Alpha

IDNamePropertyBoolean

1

Name1Property1True
2Name2Property2False
3Name3Property3True

 

Now, I'm writing a query called Beta, in Beta I want to use #"Alpha"[Name] as a list, but I need to filter on the [Boolean] value.

 

I of course can write this additional query that references #"Alpha" and will return the Name column as a list that has been filtered.

 

 

let
   #"Filtered Rows" = Table.SelectRows(#"Alpha", each #"Alpha"[Boolean] = true,
   #"Name" = #"Filtered Rows"[Name]
in
  #"Name"

 

 

 

#"Name"

List
Name1
Name3

 

Where I'm having trouble is I want to direclty incorporate the above query into Beta, so that it looks something like this... (but the derivations I've tried have not worked). For the purposes of this example, we'll assume the data in #"SomeQuery" looks like as follows:

 

SomeQuery

Name 1Column2Name3Column4Column5
<value><value><value><value><value>
<value><value><value><value><value>

 

Beta

 

 

let
  Source = #"SomeQuery"
  #"Removed Other Columns" =
    Table.SelectColumns(
        Source,
        let
          #"Filtered Rows" = Table.SelectRows(#"Alpha", each #"Alpha"[Boolean] = true),
          #"Name" = #"Filtered Rows"[Name]
        in
          #"Name"
    ),
  #"NextStep" = <some other transformation>(#"Removed Other Columns", ...),
  .....
in
  #"LastStep"

 

 

 

The result of #"Removed Other Columns" should look like:

 

#"Removed Other Columns"

Name1Name3
<value><value>
<value><value>


I've tried several different syntaxual approaches and I'm not getting the result I expect, which is to carry on with the other steps. Instead I get the result of #"Name" not #"LastStep".

 

Thanks!

3 REPLIES 3
rpiboy_1
Helper V
Helper V

Bumping this up as I was hoping someone could lend some advice/input.

AntrikshSharma
Community Champion
Community Champion

@rpiboy_1 Share a mock up of the data with the code that you can written so far, you can share the file using google or onedrive.

I've added some additional detail to the original post to help further clarify the desired result and the form of the input.

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.