<?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 Create a new table based on specific row column data in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353727#M172860</link>
    <description>&lt;P&gt;Please help! We are trying to pull individual row/column data from a dataset and put those rows into a new table&lt;/P&gt;&lt;P&gt;1) Get a listing of data from the original dataset (this data represents two joined tables)&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) Refine the output from step 1 to flatten it as shown below in the image:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;3) Create a new table with Step 2 data and filter out any that do not have 'x' in each row/column&amp;nbsp; as shown below:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;4) get rid of empty rows...&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 07 Jan 2025 16:18:21 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2025-01-07T16:18:21Z</dc:date>
    <item>
      <title>Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353727#M172860</link>
      <description>&lt;P&gt;Please help! We are trying to pull individual row/column data from a dataset and put those rows into a new table&lt;/P&gt;&lt;P&gt;1) Get a listing of data from the original dataset (this data represents two joined tables)&amp;nbsp;&lt;/P&gt;&lt;P&gt;2) Refine the output from step 1 to flatten it as shown below in the image:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;3) Create a new table with Step 2 data and filter out any that do not have 'x' in each row/column&amp;nbsp; as shown below:&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;4) get rid of empty rows...&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jan 2025 16:18:21 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353727#M172860</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-01-07T16:18:21Z</dc:date>
    </item>
    <item>
      <title>Re: Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353772#M172861</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt;&amp;nbsp;- This isn't a problem for DAX to fix. This is best off done in Power Query.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I suggest you reveiw this video as there is likely to be some guidance as to how you can solve this challenge easily:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.youtube.com/watch?v=HAfpyY2OvZQ" target="_blank"&gt;https://www.youtube.com/watch?v=HAfpyY2OvZQ&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If this helps, please accept as the solution so others with the same challenge can find the answer.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jan 2025 16:52:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353772#M172861</guid>
      <dc:creator>mark_endicott</dc:creator>
      <dc:date>2025-01-07T16:52:45Z</dc:date>
    </item>
    <item>
      <title>Re: Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353911#M172869</link>
      <description>&lt;P&gt;That video does not help - he is only truncating tables together.&amp;nbsp; We need to create a new table based on the 'x' showing up in row/column combination as shown in the pictures...&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 07 Jan 2025 18:52:08 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4353911#M172869</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-01-07T18:52:08Z</dc:date>
    </item>
    <item>
      <title>Re: Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4354541#M172895</link>
      <description>&lt;P&gt;Hi&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;I create a table as you mentioned.&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;Then I think you can go to Power Query and you can use Advanced Editor.&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;let
    Source = Table.FromRecords({
        [Number="A", A=null, B=1, C=1, D=null],
        [Number="B", A=1, B=null, C=1, D=null],
        [Number="C", A=1, B=1, C=null, D=null],
        [Number="D", A=null, B=null, C=null, D=null]
    }),
    Unpivoted = Table.UnpivotOtherColumns(Source, {"Number"}, "Attribute", "Value"),
    Filtered = Table.SelectRows(Unpivoted, each [Value] = 1),
    Grouped = Table.Group(Filtered, {"Number"}, {{"Value", each Text.Combine(List.Transform([Attribute], Text.From), ","), type text}})
in
    Grouped&lt;/LI-CODE&gt;
&lt;P&gt;So you can get what you want.&lt;/P&gt;
&lt;P&gt;&lt;img /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Best Regards&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Yilong Zhou&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;If this post&amp;nbsp;&lt;STRONG&gt;&lt;I&gt;helps&lt;/I&gt;&lt;/STRONG&gt;, then please consider&amp;nbsp;&lt;STRONG&gt;&lt;I&gt;Accept it as the solution&lt;/I&gt;&lt;/STRONG&gt;&amp;nbsp;to help the other members find it more quickly.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jan 2025 06:09:20 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4354541#M172895</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-01-08T06:09:20Z</dc:date>
    </item>
    <item>
      <title>Re: Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4354834#M172896</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt;&amp;nbsp;- I was just trying to show you some of the techniques you would need to use, so you couldlear. Maybe I used the wrong video.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Anonymous&lt;/LI-USER&gt;&amp;nbsp;has given you a great solution, so go with that.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jan 2025 09:17:45 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4354834#M172896</guid>
      <dc:creator>mark_endicott</dc:creator>
      <dc:date>2025-01-08T09:17:45Z</dc:date>
    </item>
    <item>
      <title>Re: Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4355283#M172913</link>
      <description>&lt;P&gt;Thank you so much Yilong!&amp;nbsp; This is closer to what we are trying to get but the numbers change (based on the csv sheet that is incoming) and there are nearly 50 columns and hundreds of rows in the data. How would I make this more dynamic please? Can some sort of IF or Switch be used to test the values in each row/column combination?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jan 2025 13:13:55 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4355283#M172913</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2025-01-08T13:13:55Z</dc:date>
    </item>
    <item>
      <title>Re: Create a new table based on specific row column data</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4355380#M172920</link>
      <description>&lt;P&gt;Anonymous&lt;/LI-USER&gt;&amp;nbsp;- The example provided by&amp;nbsp;Anonymous&lt;/LI-USER&gt;&amp;nbsp; was just that. The source step contains a static data table that recreates the data supplied in your screenshot.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You need to replace the code in the source step with a connection to your csv file, this should give you a start on that: &lt;A href="https://goanalyticsbi.com/how-to-connect-to-csv-data-in-power-bi-desktop/" target="_blank" rel="noopener"&gt;https://goanalyticsbi.com/how-to-connect-to-csv-data-in-power-bi-desktop/&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then you need to make the code supplied matches the first column name in your CSV. If your first column is called Number it will work fine, if not, you need to make sure you change "Number" in the steps that begin with Unpivoted = and Grouped =&lt;/P&gt;</description>
      <pubDate>Wed, 08 Jan 2025 14:31:58 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Create-a-new-table-based-on-specific-row-column-data/m-p/4355380#M172920</guid>
      <dc:creator>mark_endicott</dc:creator>
      <dc:date>2025-01-08T14:31:58Z</dc:date>
    </item>
  </channel>
</rss>

