<?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 Check Orders Within A Given Date in Developer</title>
    <link>https://community.fabric.microsoft.com/t5/Developer/Check-Orders-Within-A-Given-Date/m-p/270473#M8209</link>
    <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm new to Power BI.&amp;nbsp;For my&amp;nbsp;1st project I&amp;nbsp;am trying to determine if an order came from a marketing campaign.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a list of campaigns, the customers involved and the start and end date they ran from.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I am trying to figure out is for every order is the customer in a campaign and have ordered between the start and end date&amp;nbsp;the campaign ran for.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this makes sense.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have set up 3 spread sheets:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Campaign Audience&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Campaign ID&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Customer ID&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Campaigns&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Campaign ID&lt;/P&gt;&lt;P&gt;Campaign Name&lt;/P&gt;&lt;P&gt;Start Date&lt;/P&gt;&lt;P&gt;End Date&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Orders&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Customer ID&lt;/P&gt;&lt;P&gt;Order Date&lt;/P&gt;&lt;P&gt;Product&lt;/P&gt;&lt;P&gt;&lt;U&gt;&amp;nbsp;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;</description>
    <pubDate>Fri, 06 Oct 2017 10:28:16 GMT</pubDate>
    <dc:creator>molden</dc:creator>
    <dc:date>2017-10-06T10:28:16Z</dc:date>
    <item>
      <title>Check Orders Within A Given Date</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Check-Orders-Within-A-Given-Date/m-p/270473#M8209</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'm new to Power BI.&amp;nbsp;For my&amp;nbsp;1st project I&amp;nbsp;am trying to determine if an order came from a marketing campaign.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a list of campaigns, the customers involved and the start and end date they ran from.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I am trying to figure out is for every order is the customer in a campaign and have ordered between the start and end date&amp;nbsp;the campaign ran for.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hope this makes sense.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have set up 3 spread sheets:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Campaign Audience&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Campaign ID&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Customer ID&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Campaigns&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Campaign ID&lt;/P&gt;&lt;P&gt;Campaign Name&lt;/P&gt;&lt;P&gt;Start Date&lt;/P&gt;&lt;P&gt;End Date&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Orders&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Customer ID&lt;/P&gt;&lt;P&gt;Order Date&lt;/P&gt;&lt;P&gt;Product&lt;/P&gt;&lt;P&gt;&lt;U&gt;&amp;nbsp;&lt;/U&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;</description>
      <pubDate>Fri, 06 Oct 2017 10:28:16 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Check-Orders-Within-A-Given-Date/m-p/270473#M8209</guid>
      <dc:creator>molden</dc:creator>
      <dc:date>2017-10-06T10:28:16Z</dc:date>
    </item>
    <item>
      <title>Re: Check Orders Within A Given Date</title>
      <link>https://community.fabric.microsoft.com/t5/Developer/Check-Orders-Within-A-Given-Date/m-p/273169#M8227</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="43753" data-lia-user-login="molden" class="lia-mention lia-mention-user"&gt;molden&lt;/a&gt;&lt;/P&gt;
&lt;P&gt;You can either create a measure as below&lt;/P&gt;
&lt;PRE&gt;1.You can try to create a measure as below. Then you may get the respected result.
Measure =
MAXX (
    FILTER (
        campaigns,
        MAX ( orders[order date] ) &amp;gt;= campaigns[start date]
            &amp;amp;&amp;amp; MAX ( orders[order date] ) &amp;lt;= campaigns[end date]
    ),
    campaigns[campaign id ]
) 
&lt;/PRE&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or create an auxiliary table to extend the campaign row(start date and end date) to rows of each day. And then create a one to one relationship between the created table and order table.&lt;/P&gt;
&lt;PRE&gt;Table =
FILTER (
    CROSSJOIN ( 'calendar date', campaigns ),
    'calendar date'[Date] &amp;gt;= campaigns[start date]
        &amp;amp;&amp;amp; 'calendar date'[Date] &amp;lt;= campaigns[end date]
)
&lt;/PRE&gt;</description>
      <pubDate>Mon, 09 Oct 2017 08:36:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/Developer/Check-Orders-Within-A-Given-Date/m-p/273169#M8227</guid>
      <dc:creator>Eric_Zhang</dc:creator>
      <dc:date>2017-10-09T08:36:58Z</dc:date>
    </item>
  </channel>
</rss>

