Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Rounding using specific values


This topic is 7013 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

Is it possible to round up to a specific value, i.e. 6. if there are 10 units in an hour, round up to nearest unit. Cheers

Posted

Hello aflgenx,

Yes, rounding up is possibloe - and fairly easy since FileMaker 7 introduced the Ceiling( ) function.

To round up to the nearest integer, simply enclose your number in the Ceiling function. However to round up to the nearest interval (eg the nearest 6) you will need to divide your number by the interval, apply the Ceiling function, then multiply by the interval again. Eg to round up to the nearest 6:

Ceiling ( YourNumber / 6 ) * 6

- which will work equally well for positive and negative numbers and for other whole-number intervals. :P

This topic is 7013 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.