Forum Discussion
Placing a Query on Power BI service (data flow?)
Hi,
I have a query that must be used in several PBI files, and I am copying the query between them. The thing is that when this query needs to change, I dont want to have to change it in every file.
I believe there is a way to use power query on the power bi service, and to use this query in the sources? Can anyone give me a direction please? I believe this is where dataflows enter but I have not managed to apply it.
Thanks,
Hi campelliann ,
Is this query being changed when you do a new file or is it always the same? Are you adding new measures and creating new calculations or repeating the same ones?
If your query is always the same you can do one of two things:
- Create a blank report with only that query and make use of Power BI dataset (https://docs.microsoft.com/en-us/power-bi/connect-data/desktop-report-lifecycle-datasets)
- The use of this type of datasets is good because you can have an all model with relationship measures and so on that you reuse everytime you need.
- Create a dataflow and add the query in this case you need to follow this link and then create a blank query and using the advance editor copy the code from your query,
Be aware that the use of dataflows does not allow for use of local files you need to have the information online.
- Create a blank report with only that query and make use of Power BI dataset (https://docs.microsoft.com/en-us/power-bi/connect-data/desktop-report-lifecycle-datasets)
1 Reply
- MFelix
Super User
Hi campelliann ,
Is this query being changed when you do a new file or is it always the same? Are you adding new measures and creating new calculations or repeating the same ones?
If your query is always the same you can do one of two things:
- Create a blank report with only that query and make use of Power BI dataset (https://docs.microsoft.com/en-us/power-bi/connect-data/desktop-report-lifecycle-datasets)
- The use of this type of datasets is good because you can have an all model with relationship measures and so on that you reuse everytime you need.
- Create a dataflow and add the query in this case you need to follow this link and then create a blank query and using the advance editor copy the code from your query,
Be aware that the use of dataflows does not allow for use of local files you need to have the information online.
- Create a blank report with only that query and make use of Power BI dataset (https://docs.microsoft.com/en-us/power-bi/connect-data/desktop-report-lifecycle-datasets)