<?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: relationship between table and visual with 2 different dates in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3965334#M52999</link>
    <description>&lt;P&gt;Please provide sample data that covers your issue or question &lt;STRONG&gt;completely&lt;/STRONG&gt;, in a &lt;STRONG&gt;usable&lt;/STRONG&gt; format (not as a screenshot).&lt;BR /&gt;&lt;BR /&gt;Do not include sensitive information or anything not related to the issue or question. &lt;BR /&gt;&lt;BR /&gt;If you are unsure how to upload data please refer to &lt;A href="https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216&lt;/A&gt; &lt;BR /&gt;&lt;BR /&gt;Please show the expected outcome based on the sample data you provided. &lt;BR /&gt;&lt;BR /&gt;Want faster answers? &lt;A href="https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Sat, 01 Jun 2024 02:48:24 GMT</pubDate>
    <dc:creator>lbendlin</dc:creator>
    <dc:date>2024-06-01T02:48:24Z</dc:date>
    <item>
      <title>relationship between table and visual with 2 different dates</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3964575#M52993</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am facing a problem. I am working on a contracts dashboard. For this I am using 2 dates. One date is the end date of the contract, the other date is when a contract should be renewed. Now I managed to get both dates in a bar chart with the userelationship formula in dax.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Jos2410_0-1717398617140.png" style="width: 400px;"&gt;&lt;img src="https://community.fabric.microsoft.com/t5/image/serverpage/image-id/1109990i5FD8C71AFC4FAF15/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Jos2410_0-1717398617140.png" alt="Jos2410_0-1717398617140.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The only problem is that the table that comes with it does not filter with it, when I select the renewal date. It uses the active relation between date and Enddate.&lt;BR /&gt;In my bar chart I want to be able to click on both dates and the table will change with the clicked date. One time the end date, the other time the renewal date.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hopefully you can help me!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the data I used:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I used this table:&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;end date&lt;/TD&gt;&lt;TD&gt;renewal date&lt;/TD&gt;&lt;TD&gt;contract number&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6/30/2024&lt;/TD&gt;&lt;TD&gt;6/1/2024&lt;/TD&gt;&lt;TD&gt;A1&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;7/14/2024&lt;/TD&gt;&lt;TD&gt;6/14/2024&lt;/TD&gt;&lt;TD&gt;A2&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;6/20/2024&lt;/TD&gt;&lt;TD&gt;6/1/2024&lt;/TD&gt;&lt;TD&gt;A3&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;7/30/2024&lt;/TD&gt;&lt;TD&gt;7/3/2024&lt;/TD&gt;&lt;TD&gt;A4&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;7/4/2024&lt;/TD&gt;&lt;TD&gt;7/3/2024&lt;/TD&gt;&lt;TD&gt;A5&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;7/30/2024&lt;/TD&gt;&lt;TD&gt;6/30/2024&lt;/TD&gt;&lt;TD&gt;A6&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And this query for a date table (you can paste this in Advanced editor):&lt;/P&gt;&lt;P&gt;let&lt;BR /&gt;Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("dY5LCsAwCAXv4jqQ56fp2nOI979GidA2pWQ5MswzghQdowvEqBF4AWfKFsTWcd63Ca8gJci+oCXMiacAXcCtBNhWOP6Fz8c+KPMC", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [#"End date" = _t, #"Renewal date" = _t, #"Contract number" = _t]),&lt;BR /&gt;#"Changed Type with Locale" = Table.TransformColumnTypes(Source, {{"End date", type date}}, "en-GB"),&lt;BR /&gt;#"Changed Type with Locale1" = Table.TransformColumnTypes(#"Changed Type with Locale", {{"Renewal date", type date}}, "en-GB")&lt;BR /&gt;in&lt;BR /&gt;#"Changed Type with Locale1"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After that I made a relation between 'date' and 'end date'.&amp;nbsp;&lt;/P&gt;&lt;P&gt;After that I made a measure like this:&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;Count Renewal Date =&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt; (&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;COUNTROWS&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;Dates&lt;/SPAN&gt;&lt;SPAN&gt; ),&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;USERELATIONSHIP&lt;/SPAN&gt;&lt;SPAN&gt; ( &lt;/SPAN&gt;&lt;SPAN&gt;Dates&lt;/SPAN&gt;&lt;SPAN&gt;[Renewal date]&lt;/SPAN&gt;&lt;SPAN&gt;, &lt;/SPAN&gt;&lt;SPAN&gt;'Calendar'&lt;/SPAN&gt;&lt;SPAN&gt;[Date]&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 03 Jun 2024 07:13:32 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3964575#M52993</guid>
      <dc:creator>José2410</dc:creator>
      <dc:date>2024-06-03T07:13:32Z</dc:date>
    </item>
    <item>
      <title>Re: relationship between table and visual with 2 different dates</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3965334#M52999</link>
      <description>&lt;P&gt;Please provide sample data that covers your issue or question &lt;STRONG&gt;completely&lt;/STRONG&gt;, in a &lt;STRONG&gt;usable&lt;/STRONG&gt; format (not as a screenshot).&lt;BR /&gt;&lt;BR /&gt;Do not include sensitive information or anything not related to the issue or question. &lt;BR /&gt;&lt;BR /&gt;If you are unsure how to upload data please refer to &lt;A href="https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-p/963216&lt;/A&gt; &lt;BR /&gt;&lt;BR /&gt;Please show the expected outcome based on the sample data you provided. &lt;BR /&gt;&lt;BR /&gt;Want faster answers? &lt;A href="https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523" target="_blank"&gt;https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 01 Jun 2024 02:48:24 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3965334#M52999</guid>
      <dc:creator>lbendlin</dc:creator>
      <dc:date>2024-06-01T02:48:24Z</dc:date>
    </item>
    <item>
      <title>Re: relationship between table and visual with 2 different dates</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3970294#M53063</link>
      <description>&lt;P&gt;HI&amp;nbsp;&lt;a href="https://community.fabric.microsoft.com/t5/user/viewprofilepage/user-id/752806"&gt;@José2410&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;According to your description and sample data, it seems like a common multiple date fields analysis requirement.&lt;BR /&gt;For this scenario, I'd like to suggest you take a look at Greg’s blog to know how to handle with date range analysis requirement.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.fabric.microsoft.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882#:~:text=You%20have%20a%20%E2%80%9Cstart%20date%E2%80%9D%20and%20an%20%E2%80%9Cend%20date%E2%80%9D" target="_self"&gt;Before You Post, Read This: start, end date&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Xiaoxin Sheng&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jun 2024 05:33:05 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/relationship-between-table-and-visual-with-2-different-dates/m-p/3970294#M53063</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-06-04T05:33:05Z</dc:date>
    </item>
  </channel>
</rss>

