all groups > sql server new users > september 2006 >
You're in the

sql server new users

group:

Can I use sp_rename in VB program?


Re: Can I use sp_rename in VB program? Arnie Rowland
9/27/2006 12:44:41 PM
sql server new users:
Leave out the word 'OBJECT' in the strSQL.

strSQL = "sp_rename 'mytable', 'mytable1'"

--
Arnie Rowland, Ph.D.
Westwood Consulting, Inc

Most good judgment comes from experience.
Most experience comes from bad judgment.
- Anonymous


[quoted text, click to view]

Can I use sp_rename in VB program? mark
9/28/2006 3:01:17 AM
dim gConn as new adodb.connection
gConn.open "...."
strSQL = "sp_rename 'mytable', 'mytable1','OBJECT'"
gConn.Execute strSQL, , adCmdStoredProc

Why last SQL command cannot be executed?

Re: Can I use sp_rename in VB program? mark
9/29/2006 12:00:00 AM
It seems not work.

"Arnie Rowland" <arnie@1568.com> дÈëÏûÏ¢
news:OJyug1m4GHA.2536@TK2MSFTNGP06.phx.gbl...
[quoted text, click to view]

Re: Can I use sp_rename in VB program? mark
9/29/2006 12:00:00 AM
Write like this is OK:

strSQL = "exec sp_rename 'mytable', 'mytable1'"

"mark" <markiiii@sina.com> дÈëÏûÏ¢
news:e0q$Pdm4GHA.2464@TK2MSFTNGP06.phx.gbl...
[quoted text, click to view]

AddThis Social Bookmark Button