<?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: Calculated column to retrieve value over one to many relationship including if ids not matched in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050371#M160691</link>
    <description>&lt;P&gt;Thanks for replying!&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;I've put together some test data and I can give a bit more context and show you what the current result is and what the desired result would look like.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cases table:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;CaseID&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Firms table:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;CaseID&lt;/TD&gt;&lt;TD&gt;Firm&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;Firm A&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;TD&gt;Firm B&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;TD&gt;Firm C&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The tables relate to a case/claims management system, and the cases table has one row for each case in the system (identified by caseID).&amp;nbsp; The firms table has a list of cases including the firms the cases/claims are against. They are still listed by one case per row.&amp;nbsp;&amp;nbsp;&lt;BR /&gt;So if there isn't a firm recorded on the case in the case management system, it will only have a case ref row in the cases tables and not in the firms table.&lt;BR /&gt;&lt;BR /&gt;Here's my current visual, I'm trying to show what share of claims made in&amp;nbsp; a year are against two particular firms.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;However, this just shows the percentage of complaints against the firms for cases where a firm has been recorded.&amp;nbsp; Ideally what I'd like would be a fourth column for "no firm" for the cases where a firm hasn't been recorded.&lt;BR /&gt;&lt;BR /&gt;Thanks!&lt;BR /&gt;M&lt;/P&gt;</description>
    <pubDate>Fri, 19 Jul 2024 09:44:13 GMT</pubDate>
    <dc:creator>MJDS</dc:creator>
    <dc:date>2024-07-19T09:44:13Z</dc:date>
    <item>
      <title>Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4048265#M160590</link>
      <description>&lt;P&gt;I have a power BI desktop file with a direct query semantic model (which I can't amend). The cases table has a one to many relationship to the firms table, I need to use the CaseID column to retrieve the FIRM from the firms table to a calculated column in the cases table. I also need the formula to bring back "no firm" if there is no id match.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've used Power BI for a while, but have always tried to use PowerQuery/M instead of DAX until now!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here's the tables in question with fields highlighted:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;M&lt;/P&gt;</description>
      <pubDate>Thu, 18 Jul 2024 10:26:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4048265#M160590</guid>
      <dc:creator>MJDS</dc:creator>
      <dc:date>2024-07-18T10:26:24Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050006#M160666</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="777245" data-lia-user-login="MJDS" class="lia-mention lia-mention-user"&gt;MJDS&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Is it possible to provide some test data about the model and a screenshot of the desired results so that I can answer you as soon as possible?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;BR /&gt;Adamk Kong&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 07:04:37 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050006#M160666</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-07-19T07:04:37Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050371#M160691</link>
      <description>&lt;P&gt;Thanks for replying!&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;I've put together some test data and I can give a bit more context and show you what the current result is and what the desired result would look like.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cases table:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;CaseID&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Firms table:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;CaseID&lt;/TD&gt;&lt;TD&gt;Firm&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;Firm A&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;TD&gt;Firm B&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;TD&gt;Firm C&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The tables relate to a case/claims management system, and the cases table has one row for each case in the system (identified by caseID).&amp;nbsp; The firms table has a list of cases including the firms the cases/claims are against. They are still listed by one case per row.&amp;nbsp;&amp;nbsp;&lt;BR /&gt;So if there isn't a firm recorded on the case in the case management system, it will only have a case ref row in the cases tables and not in the firms table.&lt;BR /&gt;&lt;BR /&gt;Here's my current visual, I'm trying to show what share of claims made in&amp;nbsp; a year are against two particular firms.&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;However, this just shows the percentage of complaints against the firms for cases where a firm has been recorded.&amp;nbsp; Ideally what I'd like would be a fourth column for "no firm" for the cases where a firm hasn't been recorded.&lt;BR /&gt;&lt;BR /&gt;Thanks!&lt;BR /&gt;M&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:44:13 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050371#M160691</guid>
      <dc:creator>MJDS</dc:creator>
      <dc:date>2024-07-19T09:44:13Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050380#M160693</link>
      <description>&lt;P&gt;Would assigning multiple firms for a given CaseId in comma seperated format suffice ?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Here is the sample data :&lt;BR /&gt;&lt;BR /&gt;Case &amp;gt;&amp;gt;&lt;BR /&gt;CaseID,CaseName&lt;BR /&gt;1,Case A&lt;BR /&gt;2,Case B&lt;BR /&gt;3,Case C&lt;BR /&gt;4,Case D&lt;BR /&gt;5,Case E&lt;BR /&gt;&lt;BR /&gt;Firm &amp;gt;&amp;gt;&lt;BR /&gt;FirmID,CaseId,Firm&lt;BR /&gt;1,1,Firm A&lt;BR /&gt;2,1,Firm B&lt;BR /&gt;3,1,Firm C&lt;BR /&gt;4,5,Firm X&lt;BR /&gt;5,4,Firm Y&lt;BR /&gt;6,5,Firm Z&lt;BR /&gt;&lt;BR /&gt;This is the calculation for the column&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;FirmName = IF (ISBLANK(CONCATENATEX(RELATEDTABLE(Firm),Firm[Firm], ", ")),"No Firm", CONCATENATEX(RELATEDTABLE(Firm),Firm[Firm], ", "))&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Sachin Nandanwar&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:09:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050380#M160693</guid>
      <dc:creator>SachinNandanwar</dc:creator>
      <dc:date>2024-07-19T09:09:10Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050404#M160695</link>
      <description>&lt;P&gt;Hi Sachin,&lt;BR /&gt;&lt;BR /&gt;Thanks for replying - but in the Firms table, the Firm column will never be blank.&amp;nbsp; Only the cases table will have cases where there wouldn't be a firm associated.&lt;BR /&gt;&lt;BR /&gt;M&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:16:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050404#M160695</guid>
      <dc:creator>MJDS</dc:creator>
      <dc:date>2024-07-19T09:16:08Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050453#M160699</link>
      <description>&lt;P&gt;Hi,&lt;BR /&gt;Can you please use at the sample data I posted as reference and point me to where the firm column was blank.&lt;BR /&gt;&lt;BR /&gt;So if I understand your requirement corerctly a single case can be assigned to multiple firms and there would be no firm that would have a case not assigned to it.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:36:10 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050453#M160699</guid>
      <dc:creator>SachinNandanwar</dc:creator>
      <dc:date>2024-07-19T09:36:10Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050464#M160700</link>
      <description>&lt;P&gt;Here's my attempt at sample data:&lt;/P&gt;&lt;P&gt;Cases table:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;CaseID&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Firms table:&lt;/P&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;CaseID&lt;/TD&gt;&lt;TD&gt;Firm&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;Firm A&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;3&lt;/TD&gt;&lt;TD&gt;Firm B&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;4&lt;/TD&gt;&lt;TD&gt;Firm C&amp;nbsp;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I hope this explains it a bit better than I did first time!&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:42:34 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050464#M160700</guid>
      <dc:creator>MJDS</dc:creator>
      <dc:date>2024-07-19T09:42:34Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050472#M160702</link>
      <description>&lt;P&gt;So from your sample data would a unique caseid assigned to multiple Firms.&lt;BR /&gt;&lt;BR /&gt;Lets take for example CaseId &amp;gt;&amp;gt;1.Now can it be assigned to say FirmA,FirmX and FirmY at the same time ?&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:46:53 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050472#M160702</guid>
      <dc:creator>SachinNandanwar</dc:creator>
      <dc:date>2024-07-19T09:46:53Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050479#M160703</link>
      <description>&lt;P&gt;No, there would only ever be one firm associated with a CaseID.&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 09:50:48 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050479#M160703</guid>
      <dc:creator>MJDS</dc:creator>
      <dc:date>2024-07-19T09:50:48Z</dc:date>
    </item>
    <item>
      <title>Re: Calculated column to retrieve value over one to many relationship including if ids not matched</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050497#M160705</link>
      <description>&lt;P&gt;But in your initial requirement you mentioned there would be 1:M relationship across Case and Firms.&lt;BR /&gt;&lt;BR /&gt;Anyways the solution I posted earlier would still work.&lt;BR /&gt;&lt;BR /&gt;Case &amp;gt;&amp;gt;&lt;BR /&gt;CaseID,CaseName&lt;BR /&gt;1,Case A&lt;BR /&gt;2,Case B&lt;BR /&gt;3,Case C&lt;BR /&gt;4,Case D&lt;BR /&gt;5,Case E&lt;BR /&gt;6,Case F&lt;BR /&gt;&lt;BR /&gt;Firm &amp;gt;&amp;gt;&lt;BR /&gt;FirmID,CaseId,Firm&lt;BR /&gt;1,1,Firm A&lt;BR /&gt;2,2,Firm B&lt;BR /&gt;3,3,Firm C&lt;BR /&gt;4,5,Firm X&lt;BR /&gt;5,4,Firm Y&lt;BR /&gt;&lt;BR /&gt;CaseId &amp;gt;&amp;gt; 6 hasnt been assigned to any Firm,so it displays No Firm in the result below&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Jul 2024 10:00:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Calculated-column-to-retrieve-value-over-one-to-many/m-p/4050497#M160705</guid>
      <dc:creator>SachinNandanwar</dc:creator>
      <dc:date>2024-07-19T10:00:24Z</dc:date>
    </item>
  </channel>
</rss>

