Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is Whole Number? 1

Status
Not open for further replies.

MeganRoss

Programmer
Mar 17, 2009
7
US
I have to create a formula something like this:

if {order_qty}/{case_pack_qty} <> WHOLE NUMBER then "NOT FULL CASE PACK" else ""

How do I determine whether or not {order_qty}/{case_pack_qty} actually equals a whole number or if it has a fraction. Basically if it does not divide evenly I need it give me an alert.

Keep in mind {order_qty} and {case_pack_qty} are continuously changing.

Any ideas? I'm sure this is something simple but I can't figure it out.
 
Hi,
Try:
Code:
if Trunc({order_qty}/{case_pack_qty}) <> ({order_qty}/{case_pack_qty} )
then
 "NOT FULL CASE PACK" 
else ""


[profile]

To Paraphrase:"The Help you get is proportional to the Help you give.."
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top