Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
Xabinav
Creator
Creator

I need help with row numbering

CarID OldCycle IsRealCycle?
NewCycle (Trying to solve)
1234567 1 1 1
1234567 2 0 1
1234567 3 0 1
1234567 4 1 2
1234567 5 0 2
1234567 6 1 3
1234567 7 1 4

 

Hello everyone,

I'm trying to develop the field "NewCycle".

The logic is that every time that appears "1"  in the field "IsRealCycle?" , you need to "Jump" at 1 relative to its previous digit.

 

Another example...

 

CarID OldCycle IsRealCycle?
NewCycle (Trying to solve)
2222333 1 1 1
2222333 2 0 1
2222333 3 0 1
2222333 4 0 1
2222333 5 1 2

 

Thanks,

 

Labels (1)
10 Replies
Xabinav
Creator
Creator
Author

Thanks Sunny, It's work great !