Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 stored proc

Author  Topic 

cshekar
Starting Member

49 Posts

Posted - 2001-12-05 : 17:28:34
hi all,

I wanted execute sql Script file through proc or any other method
I have buch of sql script file I wanted to execute them all in one command or
in several command how do I do that
my sql script located at c:\\TSQL\TEST1.sql,TEST2,sql'etc

can code like this in the proc
EXEC 'c:\\TSQL\TEST1.sql,TEST2,sql'

please help

thanks



chandra shekar

izaltsman
A custom title

1139 Posts

Posted - 2001-12-05 : 17:50:10
You could run your scripts using OSQL utility... So in query analyzer you would execute something like:


exec xp_cmdshell 'osql /U sa /P /i c:\tsql\test1.sql'
exec xp_cmdshell 'osql /U sa /P /i c:\tsql\test2.sql'




Edited by - izaltsman on 12/05/2001 17:50:23
Go to Top of Page
   

- Advertisement -