title: How to set nulls the values of column B and column C if they already exist on column A sql?
body: <pre><code>Select BillName as A, ConsigneeName as B, ShipperName as C 
                                from Sum_Orders 
                                where (OrderStatus in ('Complete','Invoiced')
      ) 
      and 
      OrderPeriodYear IN (
      (
      YEAR(GETDATE())-1
      )
      )
      Group by billname,ConsigneeName,ShipperName
  </code></pre>
  
  <p>I'm having duplicates in A, B, C (which is expected)
  I'm trying to make a condition to 
  <strong>keep the value in A and set to nulls the values that repeat in B OR C</strong></p>
  
  <p>IF A = B or C then keep A and SET B or C to NULLS  </p>
  
  <p><a href="https://i.stack.imgur.com/uQPwe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uQPwe.png" alt="enter image description here"></a></p>
  
  <p>Thank you, guys, :D</p>