how do I use the row_number() over partition when I need the partition to be with two columns?
I tried this below, but it didn't work right. It skipped rownumbers. Where it should of been row 1 was 3 instead.
ROW_NUMBER() over(partition by(customer_nbr+ acct_nbr ) order by customer_nbr, acct_nbr asc) as rn
the data is this, the rn is what I need it to be
customer_nbr acct_nbr acct type acct rep rn
3343 0 corp mq 1
3343 1 corp sk 2
3343 2 outs dk 3