A: 

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.

Richard
It's not a project as I have connected to the database via the "Server Explorer" panel. I did a right-click on the server and the "Allow SQL/CLR Debugging" was un-checked. I checked it and then stepped into the sproc. With no success. Very frustrating and thanks for you help.
Ferdeen
Also I did create a database project that is able to run the sprocs on my machine. I would prefer to debug directly on the server.@Richard, didn't mean to say thanks and frustrated in the same sentence. Reading it back makes me look rude. Sorry. It was a real thanks.
Ferdeen
@Ferds: np, BTDTGTTS. Will add ref. to other route to enabling debugger. (Other than that, I've no idea of other things to check.)
Richard
http://acronyms.thefreedictionary.com/BTDTGTTS :0)
Ferdeen
+3  A: 

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

eglasius
+1  A: 

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.

Richard Nienaber
A: 

Hi,

Have you tried debugging locally on the server via Citrix or RDP?

Hope this helps,

Bill

Bill Mueller
+1  A: 

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.

RoadWarrior
Thanks for this I will give it a try soon.
Ferdeen