title: T-SQL: How to query/view/check/monitor the data in the temp tables/table variables used in SP (stored procedure)
body: <p>For those familiar with SSIS, in SSIS there is a data Viewer which can be connected to the data-flow between 2 data-flow component which during exeuction shows the data flowing from one component to the other.</p>
  
  <p>I would like to have the same possibility when developing or troubleshooting/step-by-step debugging  SPs.</p>
  
  <p>e.g. right now, I am Troubleshooting a SP with more than 2500 lines of Code, making use of many temp tables and table variables.</p>
  
  <p>One possibility I know is to change local temp tables and table variables to global temp tables so to query them from another query tab ie from another session and to change them back once done.</p>
  
  <p>Does anybody know whether there is any other simpler approach?</p>