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 |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2005-09-27 : 07:55:27
|
| Daniel Crane writes "I really need to be able to write a sql script, that checks for a condition before creating a stored procedure.Now I've already done the:If condition = truebegin EXECUTE('Create procedure etc...')endBut this has a problem running as a batch file, why? I don't know the same script works fine when running from Query Analyzer. Is there any other way to write the script that would be different, and possibly resolve my issue?Using SQL Server 2000." |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2005-09-27 : 08:07:11
|
| Creating Stored Procedure Dynamically is not recommendedWhy do you want to do this?MadhivananFailing to plan is Planning to fail |
 |
|
|
jen
Master Smack Fu Yak Hacker
4110 Posts |
Posted - 2005-09-28 : 02:08:33
|
| if this is to create objects as part of installerread sql-dmo in books onlineHTH--------------------keeping it simple... |
 |
|
|
|
|
|