<?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: Use columns dynamically in a calculated measure in DAX in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Use-columns-dynamically-in-a-calculated-measure-in-DAX/m-p/1094373#M15941</link>
    <description>&lt;P&gt;It sounds like you have monthly data stored in separate columns.&amp;nbsp; If so, you should unpivot those columns in the query and make your analysis much easier.&amp;nbsp; Simple model, simple DAX.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this works for you, please mark it as solution.&amp;nbsp; Kudos are appreciated too.&amp;nbsp; Please let me know if not.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Pat&lt;/P&gt;</description>
    <pubDate>Mon, 18 May 2020 12:28:49 GMT</pubDate>
    <dc:creator>mahoneypat</dc:creator>
    <dc:date>2020-05-18T12:28:49Z</dc:date>
    <item>
      <title>Use columns dynamically in a calculated measure in DAX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Use-columns-dynamically-in-a-calculated-measure-in-DAX/m-p/1093992#M15932</link>
      <description>&lt;P&gt;Hi.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have columns named "Units month 1", "Units month 2", ..., "Units month 12", which collect the sold units per month of my company.&lt;/P&gt;&lt;P&gt;I need to create a calculated measure based on the actual month; that is, if we're in March, I'd like the measure to use the column "Units month 3". The goal of this measure is to calculate the number of units sold during a month till a specific day, or even in the whole month.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can I do this? Can I use the column names dynamically? What I'd like would be something like:&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;CALCULATE(&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; SUM("Units month "+MONTH(TODAY()))&lt;BR /&gt;&amp;nbsp; &amp;nbsp;)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Mon, 18 May 2020 08:40:31 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Use-columns-dynamically-in-a-calculated-measure-in-DAX/m-p/1093992#M15932</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-05-18T08:40:31Z</dc:date>
    </item>
    <item>
      <title>Re: Use columns dynamically in a calculated measure in DAX</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Use-columns-dynamically-in-a-calculated-measure-in-DAX/m-p/1094373#M15941</link>
      <description>&lt;P&gt;It sounds like you have monthly data stored in separate columns.&amp;nbsp; If so, you should unpivot those columns in the query and make your analysis much easier.&amp;nbsp; Simple model, simple DAX.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If this works for you, please mark it as solution.&amp;nbsp; Kudos are appreciated too.&amp;nbsp; Please let me know if not.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Pat&lt;/P&gt;</description>
      <pubDate>Mon, 18 May 2020 12:28:49 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Use-columns-dynamically-in-a-calculated-measure-in-DAX/m-p/1094373#M15941</guid>
      <dc:creator>mahoneypat</dc:creator>
      <dc:date>2020-05-18T12:28:49Z</dc:date>
    </item>
  </channel>
</rss>

