Setting Query Analyzer message display buffering in SQL serve2005

  • I have a process that runs in query analyzer, that has some print statments in it to note progress.

    The problem is the output of the print statements does not appear until the job finishes.

    I am guessing there is a buffer setting somewhere that is set to queue up these messages to a limit before displaying them, but I have not been able to find anything like that.

    Is there a way to force a print message to display sooner?

    Thanks

  • please help meee!!!!!!

  • Not with Print as far as I know, but using Raiserror with a low severity (<=10) and the optional claues WITH NOWAIT may achieve what you need.

  • maybe the "dodgy" GO statement can help you out..

    print 'myfirtsnotification'

    go

    work work work

    go

    print 'mysecond notification'

    go

    .....

     

    Keep in mind when using the GO, you'll loose all declared variables (or have to redefine them after the GO)

    Johan

    Learn to play, play to learn !

    Dont drive faster than your guardian angel can fly ...
    but keeping both feet on the ground wont get you anywhere :w00t:

    - How to post Performance Problems
    - How to post data/code to get the best help[/url]

    - How to prevent a sore throat after hours of presenting ppt

    press F1 for solution, press shift+F1 for urgent solution 😀

    Need a bit of Powershell? How about this

    Who am I ? Sometimes this is me but most of the time this is me

  • thank u for replying

    my query is some thin g like this

    declare @cnt int

    set @cnt = 1

    while (@cnt <220)

    BEGIN

    begin transaction

    update D_outlet

    set OUTLET_sid=OUTLET_sid

    commit transaction

    set rowcount 1

    print @cnt

    set @cnt = @cnt+1

    end

    The update state ment above is just a dummy thing I didnt typpe it here bcos its huge....

    When the updated table is small(100 rows ) print statement works real time but when the table is huge 10000 rows big,....there are no meesaages .....

  • in your case, the "go"-solution will not work !

    You're stuck with Mike John's solution.

     

    Maybe a "select @cnt" may serve you well enough ?? (in stead of a print)

    Johan

    Learn to play, play to learn !

    Dont drive faster than your guardian angel can fly ...
    but keeping both feet on the ground wont get you anywhere :w00t:

    - How to post Performance Problems
    - How to post data/code to get the best help[/url]

    - How to prevent a sore throat after hours of presenting ppt

    press F1 for solution, press shift+F1 for urgent solution 😀

    Need a bit of Powershell? How about this

    Who am I ? Sometimes this is me but most of the time this is me

  • thank u everyone

    raiserror wrks!!!!!!

    alzdba select @cnt doesnt wrk

Viewing 7 posts - 1 through 6 (of 6 total)

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