Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

if less than certain value, then value is X

Featured Replies

  • Newbies

Can anyone help with a calculation?

My current formula is total cost is : (quantity/amount basis)* rate * distance.

But if my total cost is less than $10.00, I want the value automatically to be entered $10.00. Obviously, if zero, it will be zero.

Thanks

Essenceprt

Try this -- as a custom function or simply in a calculation


if(amount basis = 0; // test for division by zero

//then

0;

//else

let (cost=Quantity/amount basis * rate * distance;

case ( cost = 0; 0;

cost < 10; 10;

cost)

) //let

)// if

[code]

  • 2 weeks later...

How about TotalCost is a calculated field with the following:

Case((quantity/amount basis)* rate * distance=0,0,(quantity/amount basis)* rate * distance great.gif 10,(quantity/amount basis)* rate * distance,10)

Haven't tested this, so it may be humorous at best. smile.gif

Paul

I'm not sure how in practice you end up with zero - Qty = 0? But you can use the max function:

Case( quantity=0,0, Max(rate * distance * quantity/amount basis,10) )

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.