Suppressing OSQL output

  • Jose Johnson

    Ten Centuries

    Points: 1049

    I'm a relative newbie to SQL server and trying to use OSQL to extract data to be used in another app.  The output I'm getting is fine except I cannot get rid of the three lines at the end (two are blank and one says "(x rows affected)").  Does anyone know how to suppress these lines?  

    Thanks in advance for any help.

     

  • rdg

    Mr or Mrs. 500

    Points: 506

    Jose

    If you add SET NOCOUNT ON to your sql, you will not get the (x rows affected) line at the bottom of the output.  This should also take care of at least one of the blank lines.

  • Jose Johnson

    Ten Centuries

    Points: 1049

    RDG,

    That worked great.  Thanks!  You were correct -- it did leave one blank line but I think I can live with that.  I appreciate your help!

    Jose'

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

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