title: How can I dump a SELECT statement to the "Messages" pane in SQL Server mgmt studio from a stored procedure?
body: <p>I can use the PRINT statement in a stored procedure to debug my code.  I see the output in the Messages tab of SQL Server Management Studio.  How can I dump one or more entire SELECT statement outputs to that Messages tab?</p>
  
  <p>My stored procedure returns several output variables so returning a single dataset isn't an option here. I am struggling with finding a good way to debug my complex procedures.</p>