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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
webportal
Impactful Individual
Impactful Individual

EVALUATE in Power BI

Hello,


I'm not sure this question has been asked before, but I've been trying to improve my DAX skills a bit and I'm now looking at EVALUATE in DAX. I know it returns a table, but since it cannot be used in a calculated measure nor a calculated column, where can I use this function in Power BI or in Power Pivot?

Thanks for helping!

1 ACCEPTED SOLUTION

DAX can be used as a Query language.  This is when you would use Evaluate.  You can use a tool like DAX studio to query the data model.  Read my article about DAX Studio that includes some examples here http://exceleratorbi.com.au/getting-started-dax-studio/



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.

View solution in original post

5 REPLIES 5

DAX can be used as a Query language.  This is when you would use Evaluate.  You can use a tool like DAX studio to query the data model.  Read my article about DAX Studio that includes some examples here http://exceleratorbi.com.au/getting-started-dax-studio/



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.

Hi @MattAllington, I had the same question as @webportal. I thought I could return a table or matrix visual using evaluate. Anyway, can an evaluate query created in DAX studio be imported to or be called from Power BI Desktop?






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

Proud to be a Super User!




"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu.

In Power Pivot and Power BI, a table is the organisation of data in a tabular format.  It can be...

  1. physical storage of a table as part of the data model
  2. the result of a query generated at runtime using DAX as a query language
  3. A Matrix is the rendering of data in a visual in a tabular shape.  This is not the same thing as above.  A Matrix for instance could be generated by a single column of data (say a date column) and one or more measures that generate a value for each date.

 

So to your question 

 I thought I could return a table or matrix visual using evaluate. 

If you want to return a table (1 above), you can either: 

  • Load the data using Power Query (get data)
  • Create a DAX query (eg 2 above) and use the "New Table" feature of Power BI to generate and store that table in your data model.  When you do this, you simply take the DAX query and omit the EVALUATE statement.  Read my blog article here to find out more about that. https://powerpivotpro.com/2017/02/uses-for-new-table-feature-power-bi/
  • You cannot create a matrix visual using a DAX query (with or without EVALUATE).  You can however render a matrix visual using data in any table.

I hope that helps.

 



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.

Hi Matt

 

Many thanks for clarifying this for me I have been furiously teaching myself Power BI and DAX for a new role that I am taking on, I have been using your text "Learn to Write DAX" which gave me an excellent grounding using your examples and questions applied to report tables in PBI. Together with "The Definitive Guide to DAX" my knowledge is expanding but the problem that I sometimes face (which you have now cleared up for me in this instance) is that it is not always immediately clear where some of the DAX functions sit within a Power BI context.

 

Regards

AB

Hell Matt,

 

Thank you so much, I'll read your article.

I like to understand things... Man Happy

 

Best

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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