SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Getting the Most Out of SQL Server 2000's Query Analyzer, Part II


Getting the Most Out of SQL Server 2000's Query Analyzer, Part II

Author
Message
K. Brian Kelley
K. Brian Kelley
Keeper of the Duck
Keeper of the Duck (24K reputation)

Group: Moderators
Points: 24480 Visits: 1917
Comments posted to this topic are about the content posted at http://www.sqlservercentral.com/columnists/bkelley/qa2k_2_1.asp

K. Brian Kelley
@‌kbriankelley
chad
chad
Forum Newbie
Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)

Group: General Forum Members
Points: 1 Visits: 1
Brian,

What permissions are required (both on SQL Server and for NT) to allow a developer to debug a stored procedure (for both SQL7 and SQL2K)?

Thanks
Chad



Lon Ramsey
Lon Ramsey
SSC Rookie
SSC Rookie (29 reputation)SSC Rookie (29 reputation)SSC Rookie (29 reputation)SSC Rookie (29 reputation)SSC Rookie (29 reputation)SSC Rookie (29 reputation)SSC Rookie (29 reputation)SSC Rookie (29 reputation)

Group: General Forum Members
Points: 29 Visits: 9
I had not noticed the debugger. Thank you.
Have you noticed the ability to save while developing a query in the enterprise manager? I did, but the save does not prompt for a file name? Perhaps it is for future use.

Lon



Steve Jones
Steve Jones
SSC Guru
SSC Guru (144K reputation)SSC Guru (144K reputation)SSC Guru (144K reputation)SSC Guru (144K reputation)SSC Guru (144K reputation)SSC Guru (144K reputation)SSC Guru (144K reputation)SSC Guru (144K reputation)

Group: Administrators
Points: 144560 Visits: 19424
save always works. I use this every day in development. It defaults to "untitledxx", but there is the ability to change that. Have you tried "save as"?

Steve Jones
steve@dkranch.net

Follow me on Twitter: @way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
My Blog: www.voiceofthedba.com
Lou Maggio
Lou Maggio
Grasshopper
Grasshopper (11 reputation)Grasshopper (11 reputation)Grasshopper (11 reputation)Grasshopper (11 reputation)Grasshopper (11 reputation)Grasshopper (11 reputation)Grasshopper (11 reputation)Grasshopper (11 reputation)

Group: General Forum Members
Points: 11 Visits: 7
Brian,

Great Article.
About the debugger,I have been unable to run in anywhere but directly on the query analyzer on the server. MSDN mentioned something about a bug. Have you experienced this?

Lou



K. Brian Kelley
K. Brian Kelley
Keeper of the Duck
Keeper of the Duck (24K reputation)

Group: Moderators
Points: 24480 Visits: 1917
Hi Lou,

I have not. I am in the process of trying to research it. A friend of mine is also having issues (chad) and we're trying to nail down the exact permissions and settings required for the various SQL Server versions. One thing we have noticed is there is a definite difference between 7 and 2000.

K. Brian Kelley
bkelley@sqlservercentral.com
http://www.sqlservercentral.com/columnists/bkelley/

K. Brian Kelley
@‌kbriankelley
lingasamyk
lingasamyk
Forum Newbie
Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)

Group: General Forum Members
Points: 2 Visits: 1
Hi Brian Kelley,

The article is very informative. I tried the dubugging process in my server, it is sql2000 server which runs under the Win2k OS. When i try to debug the sp it says "Sp debugging may not work properly if you log on as 'Local System account' while SQL Server is configured to run as a service. You can open Event Viwer to see details
Do you wish to continue ? " and if i continues with this it executes and gives the result of the procedure and i can not able to start the debugging process after placing the breakpoint, it just executes the procedure and gives the result of the same . I was not able to use the debug commands (sep in, step out etc.,). What could be the problem. Looking forward for your reply.

Regards,
Lingasamy K



tcartwright
tcartwright
Ten Centuries
Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)Ten Centuries (1.3K reputation)

Group: General Forum Members
Points: 1309 Visits: 1
Brian take a look at this article. I was having problems until I did this :

http://support.microsoft.com/default.aspx?scid=KB;en-us;270061&

Tim C.
//Will write code for food


Tim C //Will code for food
Tatsu
Tatsu
SSCommitted
SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)

Group: General Forum Members
Points: 1612 Visits: 307

Excellent. I hope there will be more information about the templates in future articles. They are a fantastic tool for encouraging some naming and development standards. I know that is a hot topic around here



Bryant E. Byrd, BSSE MCDBA MCAD
Business Intelligence Administrator
MSBI Administration Blog
Steve Rosenbach
Steve Rosenbach
SSC-Addicted
SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)SSC-Addicted (477 reputation)

Group: General Forum Members
Points: 477 Visits: 206

I keep finding more gems in this great tool, Query Analyzer. Here are two additional tips:

1. With the default settings, using the Object Browser for scripting creates what is for me a lot of "noise" in the script. For example, scripting a table will give you something like:

CREATE TABLE [Region] (
[RegionID] [int] NOT NULL ,
[RegionDescription] [nchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
CONSTRAINT [PK_Region] PRIMARY KEY NONCLUSTERED
(
[RegionID]
  ON [PRIMARY]
) ON [PRIMARY]
GO

All those brackets and the collation clauses get in the way for me. Fortunately, you can control a lot of this by going to Tools/Options and clicking on the Script tab. I usually pick "None" as Identifier delimeter and check the "Do not script collation clause ...." option. With these two settings changed, I get the following (in my opinion, cleaner) result:

CREATE TABLE Region (
RegionID int NOT NULL ,
RegionDescription nchar (50) NOT NULL ,
CONSTRAINT PK_Region PRIMARY KEY NONCLUSTERED
(
RegionID
  ON PRIMARY
) ON PRIMARY
GO

2. Got a stored procedure that has lots of parameters that you want to test? Just right-click on it in the Object Browser and select "Open". You get a nice little "Execute Procedure" dialog box that lists all the parameters, shows their datatypes, and allows you to enter parameter values. Then click the "Execute" button to run the stored procedure. Pretty slick!

A very good article, Brian - good on ya for spreading the word about the many features in this great freebee from Microsoft.

Best regards,
SteveR





Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search