Here is a quick formula trick you can use to generate sequence numbers that only increment when there is a change.
Assuming the sequence of values are in column C from C3,
- you can write the following formula in B4 onwards (B3 will be 1, wake up…)
=IF(C4=C3,B3,B3+1) - Now just copy paste the formula over the entire range B2:Bxxx to generate sequence numbers.
How it works?
- That is for your home work for the day 😛
Browse more excel quick tips and learn something cool.














One Response to “How to compare two Excel sheets using VLOOKUP? [FREE Template]”
Maybe I missed it, but this method doesn't include data from James that isn't contained in Sara's data.
I added a new sheet, and named the ranges for Sara and James.
Maybe something like:
B2: =SORT(UNIQUE(VSTACK(SaraCust, JamesCust)))
C2: =XLOOKUP(B2#,SaraCust,SaraPaid,"Missing")
D2: =XLOOKUP(B2#,JamesCust, JamesPaid,"Missing")
E2: =IF(ISERROR(C2#+D2#),"Missing",IF(C2#=D2#,"Yes","No"))
Then we can still do similar conditional formatting. But this will pull in data missing from Sara's sheet as well.