Have you enabled SQL Server debugging in the project?
Project | Properties | Debug tab.
EDIT: Can also enable "Allow SQL/CLR Debugging" on a data connection in the server explorer.
Have you enabled SQL Server debugging in the project?
Project | Properties | Debug tab.
EDIT: Can also enable "Allow SQL/CLR Debugging" on a data connection in the server explorer.
Check this, specially the remote debugging part: http://www.dbazine.com/sql/sql-articles/cook1
For other general information on debugging sql check http://msdn.microsoft.com/en-us/library/zefbf0t6.aspx
Remember that you also have to have admin privileges on the sql server box that you're debugging on. In the past, I've had to use the RunAs option in the explorer context menu to start Visual Studio. I use the same credentials as the admin user on the sql server box.
Hi,
Have you tried debugging locally on the server via Citrix or RDP?
Hope this helps,
Bill
One issue to investigate is that any SQL Server user account involved in SQL debugging must have "execute" rights on an extended stored procedure called sp_sdidebug, a right that only the system administrator account (sa) has by default.
To check this, use the account to log into SQL Server and then type the following SQL command using SQL Server Management Studio:
EXEC master..sp_sdidebug
You’ll see either a result stating that the command completed successfully or an execute permission error. If you see the latter result, you should also check that the account has permission to the master database itself. It’s not unknown for a DBA to give permission to the stored procedure, but not to the master database.
The quickest way to grant execution rights for a SQL Server account to sp_sdidebug is to enter the following SQL:
GRANT EXECUTE ON master..sp_sdidebug TO SpecificAccountName
There's another issue, but it won't affect you as you're using Server Explorer. If you're debugging from a client application, you also have to execute the following command:
EXEC master..sp_sdidebug 'legacy_on'
Note that remote SQL Server debugging is done using the DCOM, and this can be tricky to configure properly. First, you need to install the full remote debugging components on the remote database server. You may also need to repeat this process every time the SQL Server is upgraded with a service pack or a patch.