Home Forums SQL Server 7,2000 T-SQL Round to Even (aka Banker''s Rounding) - The final function RE: Round to Even (aka Banker''''s Rounding) - The final function

  • Sergiy

    you was politely asked to stay out of this thread. The reason you got an error was because you are using Lynns function, which does not take the same parameters as mine. Try:

    DECLARE

    @enumerator DECIMAL(38, 12)

    ,@denominator DECIMAL(38, 12)

    SELECT

    @enumerator = 50

    ,@denominator = 111.111

    SELECT @enumerator/@denominator,

    dbo.fn_BRound2(@enumerator/@denominator, 2)

    ,Round(@enumerator/@denominator,2)

    Note: I'm at home now, and can't test this, (Not got SQL at Home), but simple proof reading, even after a beer, tells me you are not bothering to even read the thread properly.

    Read Harder.

    Dave J


    http://glossopian.co.uk/
    "I don't know what I don't know."