title: IF statement based on 2 conditions with else
body: <p><a href="https://i.stack.imgur.com/wh5UJ.png" rel="nofollow noreferrer">table</a></p>
  <p>I have a matrix made in Power BI being read from a SQL Server database. I have a column called <code>Name</code> that contains duplicates along with a column called <code>stack</code>, where as shown in the example table, we can have a <code>name</code> that either contains 1 duplicate <code>stack</code> value or it can also have 1 <code>stack</code> value listed in 2 <code>name</code>s, we then have a unique <code>SubName</code> that corresponds with the different combinations of <code>Name</code> and <code>Stack</code>.</p>
  <p>Along with that we have 2 columns that are called <code>Value1</code> and <code>Value2</code>; they both should be representing the same value but since it's reading a software's database and the logic is not yet ideal, we are dealing with some overstated values and duplicates.</p>
  <p>I created a conditional column that reads <code>value1</code> if a checkbox is marked or not and otherwise <code>value2</code>.</p>
  <p>I want to create a column that displays the results in red, where for every distinct <code>name</code> even if it has a duplicated <code>stack</code>, to read either <code>Value1</code> or <code>Value2</code> whichever is lowest.</p>