Forum Discussion

Sheik-Mishuk's avatar
Sheik-Mishuk
Regular Visitor
3 years ago

How to see DAX measures when the Data model resides in Azure Analysis services

Hi, I want some suggestion about below cases-

 

I am using a PBIX file which is getting data from Azure Analysis Services with DirectQuery mode. 

All the measures, calculations and power query transformations are done in the analysis services. 

I can connect the model from Tabular editor but I can't see the Dax codes of the measures.

I have read access to the model. 

 

1. What are the possible ways to see the dax codes? and how?

2. Is there any way that I can import the model to PBIX or in Excel?

3. Is there any way that I can use SQL capability to import and transform the data model?

 

Thanks in advance for your help.

8 Replies

    • Sahir_Maharaj's avatar
      Sahir_Maharaj
      Icon for Super User rankSuper User

      1. To see the DAX code of the measures in an Azure Analysis Services (AAS) model with DirectQuery mode, you need to have write access to the model.

      • Sahir_Maharaj's avatar
        Sahir_Maharaj
        Icon for Super User rankSuper User

        If you have write access, you can open the model in the SQL Server Data Tools (SSDT) and view the DAX code in the measure editor. If you don't have write access, there is no direct way to view the DAX code of the measures.

    • Sahir_Maharaj's avatar
      Sahir_Maharaj
      Icon for Super User rankSuper User

      2. Yes, it is possible to import the AAS model into Power BI Desktop or Excel. In Power BI Desktop, you can connect to the AAS model using the "Get Data" option and selecting the "Azure" category.

      • Sahir_Maharaj's avatar
        Sahir_Maharaj
        Icon for Super User rankSuper User

        In Excel, you can connect to the AAS model using the "Data" tab and selecting the "From Analysis Services" option. Note that you will need to have the appropriate credentials and access to the AAS instance.

    • Sahir_Maharaj's avatar
      Sahir_Maharaj
      Icon for Super User rankSuper User

      3. No, you cannot use SQL to import and transform the data model in this case because the data is being queried using DirectQuery mode, not Import mode. DirectQuery mode means that the data is not stored in the Power BI Desktop file or Excel workbook, but is instead queried directly from the AAS model.

      • Sahir_Maharaj's avatar
        Sahir_Maharaj
        Icon for Super User rankSuper User

        If you want to transform the data, you will need to do it in the AAS model or in Power BI Desktop or Excel using DAX or Power Query, respectively.

  • If you have any other questions or if there is anything else I can assist with, please let me know.