Round(45.923, -1)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • vensriram
    New Member
    • Aug 2010
    • 48

    Round(45.923, -1)

    Kindly explain the output of the function
    ROUND(45.923, -1)
    The answer is being shown as 50
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    You're rounding to the nearest 10 by passing in -1.

    Comment

    • vensriram
      New Member
      • Aug 2010
      • 48

      #3
      so if it is Round(42.365,-1) it will be rounded to 40 and not 50 right?

      Comment

      • Rabbit
        Recognized Expert MVP
        • Jan 2007
        • 12517

        #4
        Yes, but wouldn't it have been faster for you to run it and see the result rather than wait for someone to respond?

        Comment

        • vensriram
          New Member
          • Aug 2010
          • 48

          #5
          Hi Rabbit,
          Thanks for your reply.
          The problem is that, neither I have SQL nor ORACLE installed in my system @ my workplace. If I had that I would not have started this thread.

          Comment

          Working...