<?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: Need to return last datetime for each campaign_id from related table in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4682922#M179357</link>
    <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;,&lt;BR /&gt;Thank you for the update.I would be happy to to assist you!&lt;BR /&gt;&lt;BR /&gt;I tried usig below and it worked for me.Please use the below calculated column:&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;LastEventDateFormatted =&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;FORMAT&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;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[EventDate]&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ALL&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[CampaignID]&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;'CampaignSummary'&lt;/SPAN&gt;&lt;SPAN&gt;[CampaignID]&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;NOT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;ISBLANK&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[EventDate]&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ),&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;"YYYY-MM-DD hh:mm AM/PM"&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;Refer the attached screenshot and the file for your reference:&lt;BR /&gt;&lt;img /&gt;
&lt;P&gt;&lt;BR /&gt;If this answer meets your requirement,consider accepting it as a solution.Let me know if you require further clarification.&lt;BR /&gt;&lt;BR /&gt;Thank you.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Pallavi.&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 07 May 2025 09:36:38 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2025-05-07T09:36:38Z</dc:date>
    <item>
      <title>Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4675928#M179069</link>
      <description>&lt;P class=""&gt;Hi everyone,&lt;/P&gt;&lt;P class=""&gt;I’m trying to create a calculated column in my summary table called 'CampaignSummary' that returns the last event date for each CampaignID from a related events table called 'CampaignEvents'.&lt;/P&gt;&lt;P class=""&gt;Here’s the setup:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P class=""&gt;'CampaignSummary'[CampaignID] contains unique campaign IDs (one per row).&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P class=""&gt;'CampaignEvents'[CampaignID] contains many events per campaign, each with an event [EventDate].&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P class=""&gt;I want to return the last (most recent) EventDate from 'CampaignEvents' for each CampaignID.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P class=""&gt;What I tried:&lt;BR /&gt;&lt;BR /&gt;LastEventDate =&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; CALCULATE(&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;MAX('CampaignEvents'[EventDate]),&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;FILTER(&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 'CampaignEvents',&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 'CampaignEvents'[CampaignID] = 'CampaignSummary'[CampaignID]&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )&lt;BR /&gt;)&lt;/P&gt;&lt;P class=""&gt;Issues:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;&lt;P class=""&gt;Some results return today’s date incorrectly.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P class=""&gt;Others return blanks.&lt;/P&gt;&lt;/LI&gt;&lt;LI&gt;&lt;P class=""&gt;I want the actual last event date for each campaign.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P class=""&gt;EventDate is of data type datetime, and CampaignID exists in both tables as matching text values.&lt;/P&gt;&lt;P class=""&gt;I’m not sure if this needs to be done via TOPN, RANKX, or if Power Query would be a better option — any help would be appreciated.&lt;/P&gt;&lt;P class=""&gt;Thanks in advance!&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;IF THIS WORKS BEST IN POWER QUERY EDITOR, I WILL DO THAT WAY EITHER.&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2025 15:33:14 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4675928#M179069</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-01T15:33:14Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4675958#M179072</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt;&amp;nbsp;Two things to try:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;LastEventDate Column = MAXX( RELATEDTABLE( 'CampaignEvents' ), [EventDate] )



LastEventDate Column = 
  VAR __ID = [CampaignID]
  VAR __Table = FILTER( 'CampaignEvents', [CampaignID] = __ID )
  VAR __Result = MAXX( __Table, [EventDate] )
RETURN
  __Result&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 01 May 2025 13:53:12 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4675958#M179072</guid>
      <dc:creator>Greg_Deckler</dc:creator>
      <dc:date>2025-05-01T13:53:12Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676040#M179077</link>
      <description>&lt;P class=""&gt;Thanks! Your DAX worked in removing blanks, which is great.&lt;/P&gt;&lt;P class=""&gt;But I noticed something odd — for a campaign that was last sent around 25/12/2024, the date returned was 20/03/2025. So I think it's picking the latest date overall, even if it’s in the future.&lt;/P&gt;&lt;P class=""&gt;Is there a way to make it return only the last event that’s already happened (like before or equal to today)?&amp;nbsp;&lt;/P&gt;&lt;P class=""&gt;Thank you for the help&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2025 14:55:06 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676040#M179077</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-01T14:55:06Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676060#M179079</link>
      <description>&lt;P&gt;Hello Anonymous&lt;/LI-USER&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Try this it will work as expected.&amp;nbsp;&lt;/P&gt;&lt;P&gt;LastEventDate :=&lt;/P&gt;&lt;P&gt;VAR __ID = [CampaignID]&lt;/P&gt;&lt;P&gt;VAR __Today = TODAY()&lt;/P&gt;&lt;P&gt;VAR __Table =&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; FILTER(&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 'CampaignEvents',&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 'CampaignEvents'[CampaignID] = __ID&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;amp;&amp;amp; 'CampaignEvents'[EventDate] &amp;lt;= __Today&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; )&lt;/P&gt;&lt;P&gt;RETURN&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; MAXX(__Table, 'CampaignEvents'[EventDate])&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this solved your issue, please mark it as the accepted solution. &lt;span class="lia-unicode-emoji" title=":white_heavy_check_mark:"&gt;✅&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2025 15:23:39 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676060#M179079</guid>
      <dc:creator>Amar_Kumar</dc:creator>
      <dc:date>2025-05-01T15:23:39Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676081#M179082</link>
      <description>&lt;P&gt;I have tried the same solution but still it didn't worked.&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2025 15:31:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676081#M179082</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-01T15:31:45Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676107#M179084</link>
      <description>&lt;P&gt;Try this&lt;/P&gt;&lt;P&gt;LastEventDate =&amp;nbsp;&lt;/P&gt;&lt;P&gt;VAR __Today = TODAY()&lt;/P&gt;&lt;P&gt;RETURN&lt;/P&gt;&lt;P&gt;CALCULATE(&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; MAX('CampaignEvents'[EventDate]),&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; FILTER(&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 'CampaignEvents',&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 'CampaignEvents'[CampaignID] = EARLIER('Campaigns'[CampaignID])&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;amp;&amp;amp; 'CampaignEvents'[EventDate] &amp;lt;= __Today&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; )&lt;/P&gt;&lt;P&gt;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 May 2025 15:43:42 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4676107#M179084</guid>
      <dc:creator>Amar_Kumar</dc:creator>
      <dc:date>2025-05-01T15:43:42Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4678446#M179187</link>
      <description>&lt;P&gt;Try this DAX&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;LastEventDate =
CALCULATE(
    MAX('CampaignEvents'[EventDate]),
    RELATEDTABLE('CampaignEvents')
)&lt;/LI-CODE&gt;</description>
      <pubDate>Sat, 03 May 2025 12:09:09 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4678446#M179187</guid>
      <dc:creator>aduguid</dc:creator>
      <dc:date>2025-05-03T12:09:09Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4679860#M179255</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;,&lt;BR /&gt;Thank you&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="81736" data-lia-user-login="aduguid" class="lia-mention lia-mention-user"&gt;aduguid&lt;/a&gt;&amp;nbsp;,&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="1254590" data-lia-user-login="Amar_Kumar" class="lia-mention lia-mention-user"&gt;Amar_Kumar&lt;/a&gt;&amp;nbsp;and&amp;nbsp;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="313" data-lia-user-login="Greg_Deckler" class="lia-mention lia-mention-user"&gt;Greg_Deckler&lt;/a&gt;&amp;nbsp; for the helpful response!&lt;BR /&gt;I wanted to check in on your situation regarding the issue. Have you resolved it? If you have, please consider marking the reply that helped you or sharing your solution. It would be greatly appreciated by others in the community who may have the same question.&lt;BR /&gt;Thank you.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 May 2025 09:13:59 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4679860#M179255</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-05T09:13:59Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4682856#M179353</link>
      <description>&lt;P class=""&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;Thank you for checking in.&lt;/P&gt;&lt;P class=""&gt;Unfortunately, none of the replies resolved my issue. I appreciate the input shared so far, but I'm still looking for a solution. If anyone else has further suggestions or has encountered a similar scenario, your help would be greatly appreciated&lt;/P&gt;</description>
      <pubDate>Wed, 07 May 2025 09:07:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4682856#M179353</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-07T09:07:38Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4682922#M179357</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;Thank you for the update.I would be happy to to assist you!&lt;BR /&gt;&lt;BR /&gt;I tried usig below and it worked for me.Please use the below calculated column:&lt;/P&gt;
&lt;DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;LastEventDateFormatted =&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;FORMAT&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;CALCULATE&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;MAX&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[EventDate]&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;FILTER&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;ALL&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;),&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[CampaignID]&lt;/SPAN&gt;&lt;SPAN&gt; = &lt;/SPAN&gt;&lt;SPAN&gt;'CampaignSummary'&lt;/SPAN&gt;&lt;SPAN&gt;[CampaignID]&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;amp;&amp;amp; &lt;/SPAN&gt;&lt;SPAN&gt;NOT&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;ISBLANK&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[EventDate]&lt;/SPAN&gt;&lt;SPAN&gt;))&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; )&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; ),&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &lt;/SPAN&gt;&lt;SPAN&gt;"YYYY-MM-DD hh:mm AM/PM"&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;)&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;Refer the attached screenshot and the file for your reference:&lt;BR /&gt;&lt;img /&gt;
&lt;P&gt;&lt;BR /&gt;If this answer meets your requirement,consider accepting it as a solution.Let me know if you require further clarification.&lt;BR /&gt;&lt;BR /&gt;Thank you.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Pallavi.&lt;/P&gt;
&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 07 May 2025 09:36:38 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4682922#M179357</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-07T09:36:38Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4683287#M179371</link>
      <description>&lt;P&gt;Here is the sample model, it gives a clear view of the relationships. The tables (as per the model) are:&amp;nbsp;&lt;BR /&gt;&lt;SPAN&gt;'CampaignEvents'&lt;/SPAN&gt;&lt;SPAN&gt;[EventDate] is 'Events'[datetime], 'Events'[CampaignID] (has many events for CampaignID)&lt;BR /&gt;'CampaignSummary'[CampaignID] is 'CampaignMetrics_ValuesReport'[CampaignID]. (has unique 'CampaignID')&lt;BR /&gt;&lt;BR /&gt;-&amp;gt; It should&amp;nbsp;&amp;nbsp;'returns the last event date for each CampaignID from Events table'&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/SPAN&gt;-- I tried your DAX calculated column, it didnt worked. Calculated column, measure or Power Query editor solution would be helpful.&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;</description>
      <pubDate>Wed, 07 May 2025 13:32:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4683287#M179371</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-07T13:32:11Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4688625#M179562</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;Thank you for the follow-up.I would be happy to assist you!&lt;BR /&gt;I suggest trying this approach in Power Query:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;SPAN&gt;Open Power Query -&amp;gt;Transform Data.&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;In CampaignEvents, filter out blank EventDate rows&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;Group By CampaignID, aggregate Max of EventDate as LastEventDate&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;Go to CampaignSummary, Merge Queries with grouped table on CampaignID (use:Left Outer Join)&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;Expand LastEventDate column, then Apply &amp;amp; Close.&lt;BR /&gt;&lt;/SPAN&gt;&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&lt;SPAN&gt;Refer the sceenshot and updated file for your reference:&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;If my answer resolve your query,consider accepting it as solution.&lt;BR /&gt;&lt;BR /&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 12 May 2025 07:30:23 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4688625#M179562</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-12T07:30:23Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4693642#M179742</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;Following up to check whether you got a chance to review the suggestion given.I hope it helps.If so,consider accepting it as solution,it will be helpful for other members of the community who have similar problems as yours to solve it faster. Glad to help.&lt;BR /&gt;hank you.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 15 May 2025 08:16:19 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4693642#M179742</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-15T08:16:19Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4703020#M180129</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;BR /&gt;I wanted to check and see if you had a chance to review my previous message.If it resolve your query,consider accepting it as solution or share your answer and accept it.&lt;BR /&gt;&lt;BR /&gt;Thank you.&lt;/P&gt;</description>
      <pubDate>Thu, 22 May 2025 07:34:57 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4703020#M180129</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-22T07:34:57Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4703223#M180137</link>
      <description>&lt;P&gt;Sorry for the late response, I tried but still it didn't worked.&lt;/P&gt;</description>
      <pubDate>Thu, 22 May 2025 09:49:49 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4703223#M180137</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-22T09:49:49Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4704687#M180190</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;Thanks again for your patience and all the detailed testing.Since you have already tried all the possibilities,at this stage I’d recommend opening a Microsoft support ticket, so the team can take a closer look .&lt;BR /&gt;To raise a support ticket for Fabric and Power BI, kindly follow the steps outlined in the following guide:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://learn.microsoft.com/en-us/power-bi/support/create-support-ticket" target="_blank" rel="nofollow noopener noreferrer"&gt;How to create a Fabric and Power BI Support ticket - Power BI | Microsoft Learn&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;Hops this resolve your query.If so,give us kudos and consider accepting it as solution.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;Pallavi.&lt;/P&gt;</description>
      <pubDate>Fri, 23 May 2025 07:14:19 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4704687#M180190</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-23T07:14:19Z</dc:date>
    </item>
    <item>
      <title>Re: Need to return last datetime for each campaign_id from related table</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4713993#M180556</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;We are following up once again regarding your query. Could you please confirm if the issue has been resolved through the support ticket with Microsoft?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;If the issue has been resolved, we kindly request you to share the resolution or key insights here to help others in the community. If we don’t hear back, we’ll go ahead and close this thread.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Should you need further assistance in the future, we encourage you to reach out via the Microsoft Fabric Community Forum and create a new thread. We’ll be happy to help.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thank you for your understanding and participation.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 May 2025 11:15:41 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Need-to-return-last-datetime-for-each-campaign-id-from-related/m-p/4713993#M180556</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-05-30T11:15:41Z</dc:date>
    </item>
  </channel>
</rss>

