Bring your best ideas to the AI Use Case Contest! Enter to win 40 hours of expert engineering support and bring your vision to life using the powerful combination of Alteryx + AI. Learn more now, or go straight to the submission form.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

RecordID reset formula

gabrielmier222
7 - Meteor

I need a fromula (thinking multi-formula) that resets the RecordID back down to 1, when the date in a cell is different than the one above it. 

Example below is the excel desired output

gabrielmier222_0-1683737560614.png

 

12 REPLIES 12
john_walker
Alteryx Alumni (Retired)

I solved this by doing two things:

 

First, I updated your multi row formula to this:

 

if [Date] != [Row-1:Date] then 1 else [Row-1:LINE_NO]+1 endif

 

instead of this:

 

if [Date] != [Row-1:Date] then 1 else [Row-1:RecordID]+1 endif

 

Notice you had RecordID so you were adding RecordID not LINE_NO

 

Second, I had to change the data type of LINE_NO to an INT data type so you can perform the addition/math on that field.

 

Hope that helps.

john_walker
Alteryx Alumni (Retired)

Here is updated workflow - note I had to remove the single quotes around 1 in the formula tool at the end as now that is an INT field

gabrielmier222
7 - Meteor

Thank you John, this worked!

Labels
Top Solution Authors