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.
| Author |
Topic |
|
vmurali
Yak Posting Veteran
88 Posts |
Posted - 2008-06-13 : 02:21:34
|
| Hi All, I need to create a batch file to execute some 5-6 sql scripts. I have sql scripts for creating a table and related storedprocs and I need to generate a batch file to run all this scripts. |
|
|
chiragkhabaria
Master Smack Fu Yak Hacker
1907 Posts |
Posted - 2008-06-13 : 02:47:58
|
| You can create the batch file using sqlcmd for executing your script.. look into bol for further details on sqlcmd.. And for running the batch look out for xp_cmdshell. Chiraghttp://www.chirikworld.com |
 |
|
|
vmurali
Yak Posting Veteran
88 Posts |
Posted - 2008-06-13 : 03:02:59
|
| Thanks for ur reply. I am new to creation of batch file. Is it like add statements with sqlcmd and save as *.bat file.How to execute the batch file from command promptIf possible if you can send me a steps to create a batch file and execute the batch file |
 |
|
|
chiragkhabaria
Master Smack Fu Yak Hacker
1907 Posts |
|
|
|
|
|