Truncate
Kenneth Brody
kenbrody at spamcop.net
Wed Dec 11 13:41:27 PST 2013
On 12/11/2013 2:48 PM, Matt Sherrill wrote:
> Ken,
> Thanks for your help - and sorry for taking so long to reply.
> Your solution of:
>
> Result = 46949.500 - mod("46949.500","100")
> Result = 46949.500 - 495
ITYM: 46949.500 - 49.500
(Where did you get "495" from?)
> Result = 46454.5
ITYM: 46900
(Which is the answer you use below as the desired result.)
> ... doesn't seem to work - unless I don't understand how MOD works?
Did you try it?
Your use of "495" above, rather than "49.5" makes me think that you
misunderstand MOD(). Can you describe what you think it does?
> Let me try to restate my problem.
>
> If I have a calculated number of 46949.5, I need it to round the nearest hundreds "after" dropping the decimal.
>
> So the steps would proceed like this:
> 1. 46,949.5 becomes 46,949
> 2. 46,949 rounds to the nearest hundreds to become 46,900
I'm not sure why you need to "drop the decimal" first, as the result is the
same.
--
Kenneth Brody
More information about the Filepro-list
mailing list