<?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: If function in DAX Commands and Tips</title>
    <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188973#M51131</link>
    <description>&lt;P&gt;Thanks, it works&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But then two more questions:&lt;/P&gt;&lt;P&gt;1. How do I write the aggregation, if I want 1 (one) if test[item] = A or if test[item] = B or if test[item] =C&lt;/P&gt;&lt;P&gt;2. Can the aggregation be written so if the condition is fullfilled (i.e. 1) the font shall change to Serge UI Bold&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 14 Nov 2021 20:05:11 GMT</pubDate>
    <dc:creator>Kjaer</dc:creator>
    <dc:date>2021-11-14T20:05:11Z</dc:date>
    <item>
      <title>If function</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188942#M51122</link>
      <description>&lt;P&gt;I have a table like this&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;I want to make a new measure&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;img /&gt;&lt;/P&gt;&lt;P&gt;But it doesn´t work. I get this error-message:&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class="Y2IQFc"&gt;A single value for the 'item' column in the 'test' table cannot be determined. This can happen when a measurement formula refers to a column that contains many values ​​without specifying an aggregation function such as min, max, count or sum to form a single result.&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;Can anyone help me?&lt;/P&gt;</description>
      <pubDate>Sun, 14 Nov 2021 18:27:57 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188942#M51122</guid>
      <dc:creator>Kjaer</dc:creator>
      <dc:date>2021-11-14T18:27:57Z</dc:date>
    </item>
    <item>
      <title>Re: If function</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188960#M51126</link>
      <description>&lt;P&gt;This code should work if you are writing a calculated column that has the row context to make sense of it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;However, for a measure, it doesn't automatically know which row you're referring to when you write "test[item]", so you need to use an aggregation like MAX or SELECTEDVALUE like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;IF ( SELECTEDVALUE ( test[item] ) = "A", 1, 0 )&lt;/LI-CODE&gt;</description>
      <pubDate>Sun, 14 Nov 2021 19:06:40 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188960#M51126</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2021-11-14T19:06:40Z</dc:date>
    </item>
    <item>
      <title>Re: If function</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188973#M51131</link>
      <description>&lt;P&gt;Thanks, it works&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt;&lt;/P&gt;&lt;P&gt;But then two more questions:&lt;/P&gt;&lt;P&gt;1. How do I write the aggregation, if I want 1 (one) if test[item] = A or if test[item] = B or if test[item] =C&lt;/P&gt;&lt;P&gt;2. Can the aggregation be written so if the condition is fullfilled (i.e. 1) the font shall change to Serge UI Bold&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 14 Nov 2021 20:05:11 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2188973#M51131</guid>
      <dc:creator>Kjaer</dc:creator>
      <dc:date>2021-11-14T20:05:11Z</dc:date>
    </item>
    <item>
      <title>Re: If function</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2190938#M51231</link>
      <description>&lt;P&gt;&lt;a href="javascript:void(0)" data-lia-user-mentions="" data-lia-user-uid="39298" data-lia-user-login="AlexisOlson" class="lia-mention lia-mention-user"&gt;AlexisOlson&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Two more questions:&lt;/P&gt;&lt;P&gt;1. How do I write the aggregation, if I want 1 (one) if test[item] = A or if test[item] = B or if test[item] =C&lt;/P&gt;&lt;P&gt;2. Can the aggregation be written so if the condition is fullfilled (i.e. 1) the font shall change to Serge UI Bold&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;</description>
      <pubDate>Mon, 15 Nov 2021 19:43:56 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2190938#M51231</guid>
      <dc:creator>Kjaer</dc:creator>
      <dc:date>2021-11-15T19:43:56Z</dc:date>
    </item>
    <item>
      <title>Re: If function</title>
      <link>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2190948#M51234</link>
      <description>&lt;P&gt;1. I'd probably write that like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;IF ( SELECTEDVALUE ( test[item] ) IN { "A", "B", "C" }, 1, 0 )&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;2. Font face cannot be conditionally formatted like font color and background color can be. Not yet anyway.&lt;/P&gt;
&lt;P&gt;You may want to vote and comment on related ideas like this one:&lt;BR /&gt;&lt;A href="https://ideas.powerbi.com/ideas/idea/?ideaid=29c97607-0484-4f4a-821a-d1a43ff9fc41" target="_blank"&gt;https://ideas.powerbi.com/ideas/idea/?ideaid=29c97607-0484-4f4a-821a-d1a43ff9fc41&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Nov 2021 19:54:19 GMT</pubDate>
      <guid>https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/If-function/m-p/2190948#M51234</guid>
      <dc:creator>AlexisOlson</dc:creator>
      <dc:date>2021-11-15T19:54:19Z</dc:date>
    </item>
  </channel>
</rss>

