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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
LucaA
Helper IV
Helper IV

Bring a measure of the data model back into PQ

Hi all,

i am using PQ and PP data model. I would like to reimport in PQ an allocation driver calculated by the data model. So I have in excel a standard table with some output calculated with "CUBEVALUE" formula and i would like to bring this table back to PQ to use them to do additional allocation (directly in PQ) and bring the results into the data model again. (i am not using Power Pivot to calculate the allocation driver because i should use several measure to cover all the options)

Is this possible or it creates a sort of "circular reference"? Is the whole data model able to update correctly recalculating the whole flow?

thanks

Luca

4 REPLIES 4
mahoneypat
Microsoft Employee
Microsoft Employee

What calculation are you doing on DAX/PowerPivot side?  The simplest approach would be to reproduce your calculation in your query. 

 

However, you can load your initial table from the query editor, add it to the local model, add your calculated column(s) with DAX, and then make a new query using that table as the source.  It is not a recommended practice but it can be done.

 

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


Hi @mahoneypat 

 

May be a silly question but how do I query a table with DAX columns as a source in the same pbix? What do I pick as data source for Query2?

 

So I have Query1 which I load, add an extra column with DAX, and then I want to get the entire thing back into PowerQuery as Query2, while staying in the same project. 

 

Also, I imagine there is some limitation to this - for instance if I would then use Query2 in an additional step in Query1, I presume that would be some sort of a circular reference error, right?

 

Thanks for your help!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





@mahoneypat i did not understand your solution.

However i am calculating allocation drivers. I could do them directly in PQ but it would require a lot of "Group by" functions and it slows down the model.

Moreover to do them as Measure in PP it would require to create a measure for each allocation driver for each period and they are too many

Hi @LucaA ,

 

Is the PQ you mean in Excel or power bi?

Check whether below reference help:

https://excel.city/2018/11/filter-excel-function-cubevalue-connected-to-power-bi/

 

Best Regards,
Kelly

Did I answer your question? Mark my raeply as a solution!

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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

Top Solution Authors