6/17/21: We have completed maintenance for the Search functionality on the Community. If you are seeing any issues, please try to clear your cache first. If the issue persists please email Community@alteryx.com

Alteryx Designer Discussions

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

Round to nearest multiple

ayadav8
8 - Asteroid

Hey,

 

I need to update "Recommended Order" which is a round up number of "order" quantity to the nearest multiple of "carton qty". Attached is an example of the scenario.  and "Recommended order" need to be always higher than "Order" quantity.

 

Thank you!

 

 

3 REPLIES 3
jrgo
13 - Pulsar
= ROUND(([Order]/[Carton qty]) + 0.4) * [Carton qty]

Should do the trick!

***minor edit in case the division is a whole number***
jrgo
13 - Pulsar
Ceiling function would actually be more appropriate as I think of it.

CEIL([Order]/[Carton qty]) * [Carton qty]
ayadav8
8 - Asteroid

Thanks @jrgo. the logic works.

Labels