• dwilliscp (6/24/2013)


    is there a limit on what gets printed?

    Yes. In SSMS 2012 go to Tools > Options > Query Results > SQL Server > Results to ... and increase the number.

    Instead of PRINT though, put this at the end of your batch and you'll never have to worry about that truncation problem again:

    SELECT @sql AS [processing-instruction(query)]

    FOR XML PATH(''),

    TYPE;

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato