how to get the print output from sql server

  • Put them in a temp or perm table and then Bulk Copy them out.

    Steve Jones

    steve@dkranch.net

  • Hi, putting my data into a temp table is a good idea. But I go this problem:

    Because my data is pieced together from around 30 tables. After concating those data, each row's length might be around 32000 chars.

    When I tried to create a temp table with couple of columns of varchar(8000), I got the warning:

    the table mv_temp_table has been created but its maximum row size (32340) execeeds the maximum number of bytes per row (8060).

    INSERT or UPDATE of a row in this table will fail if the resulting row length exceeds 8060 bytes.

    Any suggestion on the workaround is appreciated.

  • Use a text datatype or multiple tables/rows. Not sure how this will work with a bulk copy out, have to test it.

    Steve Jones

    steve@dkranch.net

  • I created a table with a column of text type.

    Insert some data. BCP works fine!

    Thank you very much.

  • You are welcome. Out of curiosity, how many columns are you outputting?

    Steve Jones

    steve@dkranch.net

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

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