Rounding the decimals

  • I have numbers like 3999.99 should be rounded to 4.0 and 333.33 to 334 .

    I tries round function and also =Math.Round(####,0, system.MidpointRounding.AwayFromZero)

    I am not gettiong expected result.

    Can anyone help me with this???

    Thanks,

    Komal

  • Math.Ceiling(3.99) will round it up to the nearest integer...is that what you want? so Math.Ceiling(3.09) =4 also.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • I use the STR function where I can, it works like a charm.

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply