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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Dynamic Query from Dataflow as a Source

Hello. I really hope someone can help me.

 

Does anyone know if it is possible to use M Dynamic Query using Power BI Dataflow as a source? I have seen examples using SQL and Azure as sources like in the pictures below.

 

LuciannaFG_1-1650977344792.png

 

In the image above, the parameters are being referenced in the Source line of code. The parameters are created in Desktop and referenced in M code like in the image above, but how can I do this if when I import data from a dataflow, I have this line of code?

LuciannaFG_2-1650977596789.png

 

Really hope someone knows where can I reference the parameter in this case.

 

For information, my two first lines of code in the Power Query when I am creating a dataflow is the following:

 

let
  selectedCountry = Text.From(CountryParameter),
  Source = Xml.Tables(Web.Contents("https://emm.newsbrief.eu" , [RelativePath="rss/rss?type=category&id="&selectedCountry&"]))
 
So, how can I referenced the CountryParameter in Desktop if when I importa the dataset, it is like that:
 
LuciannaFG_2-1650977596789.png
 
Thank you.
Kind regards

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

 

You may check this:

Power Query (M)agic: Parameters for Dataflows!

And the link below is included in the article above and maybe a better solution.

Pimp the dataflows connector in Power BI

 

 

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.

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi @Anonymous ,

 

There's a connector you can connect directly, why not give it a try?

vstephenmsft_0-1651213609752.png

Reference: Configure and consume a dataflow - Power BI | Microsoft Docs

 

 

 

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.

Anonymous
Not applicable

Hi @Anonymous 

 

Thank you so much for replying! I was loosing hope. I was definitely not clear on my question. So, I used the dataflow connector you showed in your message. 

I am struggling in creating Dynamic M Query Parameters, where I can let report viewers to use filters or slicers to set the value of countries. 

 

After I connect the dataset using the dataflow connector in Power BI Desktop, this line of code appears to me in Power Query:

let

Source = PowerPlatform.Dataflows(null),
Workspaces = Source{[Id="Workspaces"]}[Data]

 

I searched everwhere and I cannot find a way to reference a parameter on that. Do you know a way of doing it?

 

Thank you for your attention.

Kind regards,

Lucianna

Anonymous
Not applicable

Hi @Anonymous ,

 

You may check this:

Power Query (M)agic: Parameters for Dataflows!

And the link below is included in the article above and maybe a better solution.

Pimp the dataflows connector in Power BI

 

 

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.

Anonymous
Not applicable

Thank you @Anonymous !

 

That helps.

 

Kind regards,

Lucianna

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors
Top Kudoed Authors