<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Dax code not working in Power Automate in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-code-not-working-in-Power-Automate/m-p/3862358#M150884</link>
    <description>&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;Dax code from power bi performance analyzer doesn't work when put into power automate flow.&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;31m ago&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to have power automate export a particular matrix table and and save it into sharepoint. I have created the flow but the code i am pasting for the matrix i need exporting doesnt work. Im not sure how as i used&amp;nbsp;&lt;SPAN&gt;&lt;SPAN class=""&gt;performance analyser and recorded the tables being refreshed to get the code.&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Any help would be great&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;I am trying to replicate this in an exported excel document with the DAX code below&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;// DAX Query&lt;BR /&gt;DEFINE&lt;BR /&gt;  VAR __DS0FilterTable =&amp;nbsp;&lt;BR /&gt;    TREATAS(&lt;BR /&gt;      {"Armadillo",&lt;BR /&gt;        "Director",&lt;BR /&gt;        "Essentials",&lt;BR /&gt;        "Kickstart",&lt;BR /&gt;        "Plus",&lt;BR /&gt;        "Standard",&lt;BR /&gt;        "Umbrella"},&lt;BR /&gt;      'si_membership'[Grade]&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0FilterTable2 =&amp;nbsp;&lt;BR /&gt;    TREATAS({"Valid",&lt;BR /&gt;      "Pending Cancelled"}, 'si_membership'[Subscription Status])&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0Core =&amp;nbsp;&lt;BR /&gt;    SUMMARIZECOLUMNS(&lt;BR /&gt;      ROLLUPADDISSUBTOTAL('Calendar PQ'[Week number (month)], "IsGrandTotalRowTotal"),&lt;BR /&gt;      ROLLUPADDISSUBTOTAL('si_membership'[Grade], "IsGrandTotalColumnTotal"),&lt;BR /&gt;      __DS0FilterTable,&lt;BR /&gt;      __DS0FilterTable2,&lt;BR /&gt;      "Count_of_Subscription", 'Tenure calculations'[Count of Subscription]&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0PrimaryWindowed =&amp;nbsp;&lt;BR /&gt;    TOPN(&lt;BR /&gt;      102,&lt;BR /&gt;      SUMMARIZE(__DS0Core, 'Calendar PQ'[Week number (month)], [IsGrandTotalRowTotal]),&lt;BR /&gt;      [IsGrandTotalRowTotal],&lt;BR /&gt;      0,&lt;BR /&gt;      'Calendar PQ'[Week number (month)],&lt;BR /&gt;      1&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0SecondaryBase =&amp;nbsp;&lt;BR /&gt;    SUMMARIZE(__DS0Core, 'si_membership'[Grade], [IsGrandTotalColumnTotal])&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0Secondary =&amp;nbsp;&lt;BR /&gt;    TOPN(102, __DS0SecondaryBase, [IsGrandTotalColumnTotal], 1, 'si_membership'[Grade], 1)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0BodyLimited =&amp;nbsp;&lt;BR /&gt;    NATURALLEFTOUTERJOIN(&lt;BR /&gt;      __DS0PrimaryWindowed,&lt;BR /&gt;      SUBSTITUTEWITHINDEX(&lt;BR /&gt;        __DS0Core,&lt;BR /&gt;        "ColumnIndex",&lt;BR /&gt;        __DS0Secondary,&lt;BR /&gt;        [IsGrandTotalColumnTotal],&lt;BR /&gt;        ASC,&lt;BR /&gt;        'si_membership'[Grade],&lt;BR /&gt;        ASC&lt;BR /&gt;      )&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EVALUATE&lt;BR /&gt;  __DS0Secondary&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ORDER BY&lt;BR /&gt;  [IsGrandTotalColumnTotal], 'si_membership'[Grade]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EVALUATE&lt;BR /&gt;  __DS0BodyLimited&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ORDER BY&lt;BR /&gt;  [IsGrandTotalRowTotal] DESC, 'Calendar PQ'[Week number (month)], [ColumnIndex]&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;has context menu&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Tue, 23 Apr 2024 12:45:48 GMT</pubDate>
    <dc:creator>MrAtkinson</dc:creator>
    <dc:date>2024-04-23T12:45:48Z</dc:date>
    <item>
      <title>Dax code not working in Power Automate</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-code-not-working-in-Power-Automate/m-p/3862358#M150884</link>
      <description>&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;Dax code from power bi performance analyzer doesn't work when put into power automate flow.&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;SPAN class=""&gt;&lt;SPAN class=""&gt;31m ago&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&lt;DIV class=""&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to have power automate export a particular matrix table and and save it into sharepoint. I have created the flow but the code i am pasting for the matrix i need exporting doesnt work. Im not sure how as i used&amp;nbsp;&lt;SPAN&gt;&lt;SPAN class=""&gt;performance analyser and recorded the tables being refreshed to get the code.&amp;nbsp;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;Any help would be great&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;I am trying to replicate this in an exported excel document with the DAX code below&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;img /&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;// DAX Query&lt;BR /&gt;DEFINE&lt;BR /&gt;  VAR __DS0FilterTable =&amp;nbsp;&lt;BR /&gt;    TREATAS(&lt;BR /&gt;      {"Armadillo",&lt;BR /&gt;        "Director",&lt;BR /&gt;        "Essentials",&lt;BR /&gt;        "Kickstart",&lt;BR /&gt;        "Plus",&lt;BR /&gt;        "Standard",&lt;BR /&gt;        "Umbrella"},&lt;BR /&gt;      'si_membership'[Grade]&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0FilterTable2 =&amp;nbsp;&lt;BR /&gt;    TREATAS({"Valid",&lt;BR /&gt;      "Pending Cancelled"}, 'si_membership'[Subscription Status])&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0Core =&amp;nbsp;&lt;BR /&gt;    SUMMARIZECOLUMNS(&lt;BR /&gt;      ROLLUPADDISSUBTOTAL('Calendar PQ'[Week number (month)], "IsGrandTotalRowTotal"),&lt;BR /&gt;      ROLLUPADDISSUBTOTAL('si_membership'[Grade], "IsGrandTotalColumnTotal"),&lt;BR /&gt;      __DS0FilterTable,&lt;BR /&gt;      __DS0FilterTable2,&lt;BR /&gt;      "Count_of_Subscription", 'Tenure calculations'[Count of Subscription]&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0PrimaryWindowed =&amp;nbsp;&lt;BR /&gt;    TOPN(&lt;BR /&gt;      102,&lt;BR /&gt;      SUMMARIZE(__DS0Core, 'Calendar PQ'[Week number (month)], [IsGrandTotalRowTotal]),&lt;BR /&gt;      [IsGrandTotalRowTotal],&lt;BR /&gt;      0,&lt;BR /&gt;      'Calendar PQ'[Week number (month)],&lt;BR /&gt;      1&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0SecondaryBase =&amp;nbsp;&lt;BR /&gt;    SUMMARIZE(__DS0Core, 'si_membership'[Grade], [IsGrandTotalColumnTotal])&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0Secondary =&amp;nbsp;&lt;BR /&gt;    TOPN(102, __DS0SecondaryBase, [IsGrandTotalColumnTotal], 1, 'si_membership'[Grade], 1)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;  VAR __DS0BodyLimited =&amp;nbsp;&lt;BR /&gt;    NATURALLEFTOUTERJOIN(&lt;BR /&gt;      __DS0PrimaryWindowed,&lt;BR /&gt;      SUBSTITUTEWITHINDEX(&lt;BR /&gt;        __DS0Core,&lt;BR /&gt;        "ColumnIndex",&lt;BR /&gt;        __DS0Secondary,&lt;BR /&gt;        [IsGrandTotalColumnTotal],&lt;BR /&gt;        ASC,&lt;BR /&gt;        'si_membership'[Grade],&lt;BR /&gt;        ASC&lt;BR /&gt;      )&lt;BR /&gt;    )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EVALUATE&lt;BR /&gt;  __DS0Secondary&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ORDER BY&lt;BR /&gt;  [IsGrandTotalColumnTotal], 'si_membership'[Grade]&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;EVALUATE&lt;BR /&gt;  __DS0BodyLimited&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ORDER BY&lt;BR /&gt;  [IsGrandTotalRowTotal] DESC, 'Calendar PQ'[Week number (month)], [ColumnIndex]&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;SPAN class=""&gt;has context menu&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 23 Apr 2024 12:45:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-code-not-working-in-Power-Automate/m-p/3862358#M150884</guid>
      <dc:creator>MrAtkinson</dc:creator>
      <dc:date>2024-04-23T12:45:48Z</dc:date>
    </item>
    <item>
      <title>Re: Dax code not working in Power Automate</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-code-not-working-in-Power-Automate/m-p/3862656#M150898</link>
      <description>&lt;P&gt;Long shot, but trying removing the&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;'Calendar PQ'[Week number (month)],&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;      1&lt;BR /&gt;&lt;BR /&gt;from the TOPN part of the&amp;nbsp;VAR __DS0PrimaryWindowed&amp;nbsp;variable&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Apr 2024 14:14:01 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Dax-code-not-working-in-Power-Automate/m-p/3862656#M150898</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-04-23T14:14:01Z</dc:date>
    </item>
  </channel>
</rss>

