45.6. Debugging SQL Server Stored Procedures

Another incredibly useful feature of the debugging model found in Visual Studio 2008 is the capability to debug stored procedures in SQL Server databases. You'll need to first check the "Enable SQL Server debugging" setting in the Debug property page of your project, as shown in Figure 45-15. Once activated, whenever your code encounters a stored procedure, you can debug the procedure code inline with your own code.

Figure 45.15. Figure 45-15

You can even include breakpoints within a stored procedure so you can trace through the SQL Server code without halting the application code execution.

Your Windows account must be a member of the sysadmin group on SQL Server in order to debug stored procedures.

Get Professional Visual Studio® 2008 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.