title: Create new column as per value in another column in SQL/powerBI
body: <p>I have a dataset like:</p>
  <pre><code>ID    TYPE  POM   POM_new
  1234   sys   100   100
  1234   pm    101   100
  2345   pm    300   302
  2345   sys   302   302
  </code></pre>
  <p>I want to create new column (POM_new) as mentioned above. The new column should take the &quot;POM&quot; field value based on TYPE field i.e. &quot;sys&quot; .</p>
  <p>I want to do it in <strong>SQL(HANA) or Powerbi</strong>. Tried with below code but no success.</p>
  <pre><code>POM New = CALCULATE(MAX(tablename[POM]),FILTER(LPR,tablename[TYPE]=&quot;SYS&quot;),ALLEXCEPT(LPR,tablename[ID]))
  </code></pre>