• You need to create fixed sized variables for each column in the select query that can then be used to generate the result set.

     

    E.g

    declare @res1 varchar(20)

    declare @res2 varchar(10)

     

    select @res1 = left(col1,20),

    @res2 = left(col2,10)

    from table

    You will then get fixed sizes so that the columns line up.

    Also to increase width of text file use:

    -w

    For more parameters see:

    http://www.sql-server-performance.com/rd_osql.asp


    ------------------------------
    The Users are always right - when I'm not wrong!