Groups | Blog | Home
all groups > dotnet ado.net > august 2006 >

dotnet ado.net : Setting a breakpoint in sql server 2000 stored procedure from VS2005


Adrian Parker
8/31/2006 3:23:30 PM
Using..
Visual Studio 2005 Team Edition for Software Developers
SQL Server 2000 sp4 (on same machine)
Net.Framework 2.0
Windows XP (up to date with all patches)

Problem..
I'm trying to debug a stored procedure from within visual studio but when I
set a breakpoint and then start the app in debug mode, the breakpoints turn
to hollow circles with a message about symbols not loaded. I can
happily debug the stored proc from VS by selecting "Step Info Stored
Procedure" from Server Explorer, but I want to be able to do it on-the-fly
when it gets then in the code.

Any Ideas ?
--
Adrian Parker
Ingenuity At Work Ltd

v-kevy NO[at]SPAM online.microsoft.com
9/1/2006 12:00:00 AM
Hi Adrian,

I think this might be an improper configuration on VS.NET. So here is a
document about how to setup SQL stored procedure debugging. Please try to
go through it and see if this can solve this problem.

http://msdn2.microsoft.com/en-us/library/s4sszxst.aspx

Kevin Yu
Microsoft Online Community Support

==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================

(This posting is provided "AS IS", with no warranties, and confers no
rights.)
William (Bill) Vaughn
9/1/2006 8:55:05 AM
Ah sure. Get SQL Server 2005... ;)
I added a .cmd batch to my startup menu that ran an OSQL batch that executed
this command.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
INETA Speaker
www.betav.com/blog/billva
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________

[quoted text, click to view]

Adrian Parker
9/1/2006 4:09:33 PM
Thanks Kevin,

It needed Exec sp_sdidebug 'legacy_on'

Is there any way of turning it on permanently on our dev machines ?

Adrian

[quoted text, click to view]
| Hi Adrian,
|
| I think this might be an improper configuration on VS.NET. So here is a
| document about how to setup SQL stored procedure debugging. Please try to
| go through it and see if this can solve this problem.
|
| http://msdn2.microsoft.com/en-us/library/s4sszxst.aspx
|
| Kevin Yu
| Microsoft Online Community Support
|
| ==================================================
| Get notification to my posts through email? Please refer to
|
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
| ications.
| Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
| where an initial response from the community or a Microsoft Support
| Engineer within 1 business day is acceptable. Please note that each follow
| up response may take approximately 2 business days as the support
| professional working with you may need further investigation to reach the
| most efficient resolution. The offering is not appropriate for situations
| that require urgent, real-time or phone-based interactions or complex
| project analysis and dump analysis issues. Issues of this nature are best
| handled working with a dedicated Microsoft Support Engineer by contacting
| Microsoft Customer Support Services (CSS) at
| http://msdn.microsoft.com/subscriptions/support/default.aspx.
| ==================================================
|
| (This posting is provided "AS IS", with no warranties, and confers no
| rights.)
|

Adrian Parker
9/1/2006 5:42:26 PM

[quoted text, click to view]
| Ah sure. Get SQL Server 2005... ;)
| I added a .cmd batch to my startup menu that ran an OSQL batch that
executed
| this command.

lol, would love to go to 2005, but we're limited by our oldest customers..
ah well.

I've also created an isql batch to do the setting, but it's a pity you have
to do it each time.


v-kevy NO[at]SPAM online.microsoft.com
9/4/2006 12:00:00 AM
Hi Adrian,

But this seems to be the limitation in SQL 2000. Sorry for the
inconvenience.

Kevin Yu
Microsoft Online Community Support
==================================================

(This posting is provided "AS IS", with no warranties, and confers no
rights.)
Adrian Parker
9/7/2006 12:00:00 AM
keping legacy on..

add the following procedure to your master db..

CREATE PROCEDURE usp_force_legacy
AS
BEGIN
EXEC sp_sdidebug 'legacy_on'
END


then the following will tell sql server to run the procedure every time it
starts

EXEC sp_procoption 'usp_force_legacy', 'startup', 'true'



William (Bill) Vaughn
9/7/2006 8:26:08 AM
Cool. Learn something every day.
Thanks

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
INETA Speaker
www.betav.com/blog/billva
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________

[quoted text, click to view]

AddThis Social Bookmark Button