• Actually, we're doing the exact same thing here. This was the original query:

    while @i <> 1

    begin

    declare @a table(a int)

    set @rc = @i + 0.9

    set rowcount @rc

    insert into @a select id from sysobjects

    set @i = @i + 0.1

    end

    So, there was only one floating point addition which made @i<>1 TRUE, but in the if statement @i<>1 is FALSE.


    Steve Eckhart