Alteryx Designer Desktop Discussions

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

Integer Overflow (Greater Than) into Second Column

scsh4
7 - Meteor

Hey, Data Nuts!

 

I am stuck on a clean way to accomplish this task. I have tried formulas, multi-row tools, running totals, but have still not found a great way to do this. Most of the time I just step away for a bit and come back with a solution, but I'm hoping someone has a clean way to accomplish this.

 

Attached is a sample with my "current input" and "expected output." I have a workflow that references date, person, and worked time (in seconds - for use later in the workflow). Anything over 144,000 seconds is considered OT, and should move from the "regular" column to the OT column. While sometimes it will zero out the adjacent cell, other times there will be time "leftover." Essentially, each person that exceeds 144,000 in the "regular" column" should have the first 144,000 remain in that column with the excess in the OT column on its respective day. Hopefully, I've explained that well enough. And, as always, all input is greatly appreciated!

3 REPLIES 3
MarqueeCrew
20 - Arcturus
20 - Arcturus

@scsh4 

 

Hint

 

 field1 

100

144

245

 

Floor([field1] - 144,0)

 

or

 

Max([field1] - 144,0)

 

 cheers,

 

 mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
scsh4
7 - Meteor

I think that I have explained this poorly as I've been unable to come to a conclusion with FLOOR or MAX. I have reattached the modified workflow.

 

I believe I can use the running total tool to help me get where I'm going, but the instances are going to be frequent where someone hits OT before the last day of the week. In this case, if I used it the way you intended, using FLOOR or MAX in a formula would only work if I were to summarize, but I need to show by day.

 

So, if "John Doe" hits 147,600 on Wednesday, we need to subtract 3,600 from that row's time, adding the difference to the next column that represents OT. Additionally, any subsequent time for that user, in that week, will need to be pushed into the column that represents OT and zeroed out of original column.

 

Very basically, we have one column that represents time worked (in seconds) that we need to break out into new columns representing regular time (under 40 hours) and OT (over 40 hours).

scsh4
7 - Meteor

I have been able to solve this with the Running Total and Multi-Row Formula tool.

Labels