title: Partition by ignoring some columns
body: <p>I have this in the query:</p>
  
  <p><code>ROW_NUMBER() OVER (PARTITION BY (NUMB) ORDER BY MY_COL2) AS row_number</code></p>
  
  <p>this will pretty much equally assign values depending on the <code>NUMB</code> variable.
  I actually need to skip assignments for some columns where <code>MY_COL3 LIKE 'exclude'</code></p>
  
  <p>Is there an easy way to do it incorporating the logic above?</p>
  
  <p>Since if there is not, I have to create two separate queries and use the assignment above in one query, and do no assign anything in another (with exclude) and then union both queries. The problem is that this is very time consuming and large query and I want to avoid it... Looking for a quick fix if there is one...</p>
  
  <p>More details:</p>
  
  <p>this what query does now (simplified) based on NUMB=4:
  <code>
  ROW NUMBER | USER | TEXT | STATUS | 
  1 | Bill | blah1 | GOOD
  1 | Bill | blah2 | Exclude
  2 | Jack | blah3 | GOOD
  2 | Jack | blah4 | Exclude
  3 | Will | blah5 | GOOD
  3 | Will | blah6 | Exclude
  4 | Andy | blah7 | GOOD
  4 | Andy | blah8 | GOOD
  </code>
  This is what I want:
  <code>
  ROW NUMBER | USER | TEXT | STATUS | 
  1 | Bill | blah1 | GOOD
    | Bill | blah2 | Exclude
  1 | Jack | blah3 | GOOD
    | Jack | blah4 | Exclude
  2 | Will | blah5 | GOOD
    | Will | blah6 | Exclude
  3 | Andy | blah7 | GOOD
  4 | Andy | blah8 | GOOD
  </code></p>