title: How can I get the actual stored procedure line number from an error message?
body: <p>When I use SQL Server and there's an error, the error message gives a line number that has no correlation to the line numbers in the stored procedure. I assume that the difference is due to white space and comments, but is it really?</p>
  
  <p>How can I relate these two sets of line numbers to each other? If anyone could give me at least a pointer in the right direction, I'd really appreciate it.</p>
  
  <p>I'm using SQL server 2005.</p>