<?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 Re: Measure Caching in tables and circular dependency in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3525399#M135443</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="127937" data-lia-user-login="ppvinsights" class="lia-mention lia-mention-user"&gt;ppvinsights&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;please share example / file of data as input for expected output.&lt;/P&gt;</description>
    <pubDate>Thu, 09 Nov 2023 14:18:31 GMT</pubDate>
    <dc:creator>some_bih</dc:creator>
    <dc:date>2023-11-09T14:18:31Z</dc:date>
    <item>
      <title>Measure Caching in tables and circular dependency</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3524653#M135415</link>
      <description>&lt;P&gt;Hi community,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in a current report I have performance problems - I always receive a timeout in the service. Because I cannot find a better way to calculate my measures, I thought about introducing a cache table: I take my dimensions in a CROSSJOIN statement, surround it by ADDCOLUMNS and let my measure/s be caculated for every row in a new "cache table".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would love to still work with my original dimensions. But I cannot connect my dimension-columns of my "cache table" with any dimension - because I would introduce a circular dependency. Is there any best practise to solve that?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Holger&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Nov 2023 09:33:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3524653#M135415</guid>
      <dc:creator>ppvinsights</dc:creator>
      <dc:date>2023-11-09T09:33:45Z</dc:date>
    </item>
    <item>
      <title>Re: Measure Caching in tables and circular dependency</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3525399#M135443</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="127937" data-lia-user-login="ppvinsights" class="lia-mention lia-mention-user"&gt;ppvinsights&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;please share example / file of data as input for expected output.&lt;/P&gt;</description>
      <pubDate>Thu, 09 Nov 2023 14:18:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3525399#M135443</guid>
      <dc:creator>some_bih</dc:creator>
      <dc:date>2023-11-09T14:18:31Z</dc:date>
    </item>
    <item>
      <title>Re: Measure Caching in tables and circular dependency</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3525736#M135465</link>
      <description>&lt;P&gt;I just tried to build an easy example with Testdata. And, yes, sure: everything worked. So it took me a while to find a difference:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a Table called "Person". I have another table called "Order". And I have a calendar table. I have a measure "OrderValue=sum(Order[TotalDue])" - nothing special.&lt;/P&gt;&lt;P&gt;Now I build my "cache table" - I want to precalculate "total due per person per year):&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Cache table =
ADDCOLUMNS(
    CROSSJOIN(
        DISTINCT(DimKalender[Jahr]),
        DimPerson
    ),
    "value", [OrderValue]
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I try to create a relation 'Cache Table'[BusinessEntityID] - 'DimPerson'[BusinessEntityID] everything works fine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Now I change the DAX-statement a little bit - because I only want to see customers called "Yang":&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Cache table = 
var c = CALCULATETABLE(DimPerson, FILTER(DimPerson,DimPerson[LastName] = "Yang"))
return
ADDCOLUMNS(
    CROSSJOIN(
        DISTINCT(DimKalender[Jahr]),
        c
    ),
    "value", [OrderValue]
)&lt;/LI-CODE&gt;&lt;P&gt;==&amp;gt; Everything still works fine.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So I found another difference between my implementation and my example: I used a RAW Filter:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Cache table = 
var c = CALCULATETABLE(DimPerson, DimPerson[LastName] = "Yang")
return
ADDCOLUMNS(
    CROSSJOIN(
        DISTINCT(DimKalender[Jahr]),
        c
    ),
    "value", [OrderValue]
)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And now I have a circular dependency between my cache table and DimPerson.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone explain that for me...?&lt;/P&gt;</description>
      <pubDate>Thu, 09 Nov 2023 16:07:00 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3525736#M135465</guid>
      <dc:creator>ppvinsights</dc:creator>
      <dc:date>2023-11-09T16:07:00Z</dc:date>
    </item>
    <item>
      <title>Re: Measure Caching in tables and circular dependency</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3526093#M135475</link>
      <description>&lt;P&gt;Found it myself... The RAW Filter introduces "All" - and with using ALL I introduce the Blank row of the dimension. **bleep**. Obvious...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Nov 2023 18:41:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Measure-Caching-in-tables-and-circular-dependency/m-p/3526093#M135475</guid>
      <dc:creator>ppvinsights</dc:creator>
      <dc:date>2023-11-09T18:41:56Z</dc:date>
    </item>
  </channel>
</rss>

