SqlDbx Forum

SqlDbx

You are not logged in.

#1 2009-02-13 07:51:57

Dinendal
Guest

SQL SERVER : Comment before CREATE PROCEDURE

In this exemple the comment of p_test is not saved.

IF OBJECT_ID ('dbo.p_test') IS NOT NULL
    DROP PROCEDURE dbo.p_test
GO

/*
  Test Comment
*/

CREATE PROCEDURE p_test
AS
  select 1

GO

#2 2009-02-13 09:10:05

phtorche
Member

Re: SQL SERVER : Comment before CREATE PROCEDURE

Put your comment inside the procedure (view, function, ...). SqlDbx can do nothing for you, it's a server feature !

CREATE PROCEDURE p_test
AS
BEGIN
/*
  Test Comment
*/

  select 1

END
go

Offline

#3 2009-02-13 09:26:34

Dinendal
Guest

Re: SQL SERVER : Comment before CREATE PROCEDURE

Sorry I'm french.

But the Query Analyzer of sql server can do that.

In SqlDbx => when "SCRIPT CREATE"  the procedure I see the comment but it is not saved when i execute.

#4 2009-02-13 10:38:28

sqldbxhelp
Administrator

Re: SQL SERVER : Comment before CREATE PROCEDURE

SqlDbx does not send comments to Server if they placed before
CREATE PROCEDURE statement.  This is by design

Offline

#5 2009-02-13 10:47:41

sqldbxhelp
Administrator

Re: SQL SERVER : Comment before CREATE PROCEDURE

There's a way to see what SqlDbx will send to the database server.
Put cursor before comment and press Ctrl+B. The
highlighted text is what will be send to the server.

Offline

#6 2009-02-13 11:10:29

Dinendal
Guest

Re: SQL SERVER : Comment before CREATE PROCEDURE

I agree.  Thank you for the information.
And thank you for this very good software.

Board footer

Powered by FluxBB