dcsimg
Login | Register   
LinkedIn
Google+
Twitter
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.


Tip of the Day
Language: SQL
Expertise: Beginner
Mar 7, 2005

WEBINAR:

On-Demand

Building the Right Environment to Support AI, Machine Learning and Deep Learning


Create and Drop Stored Procedures as a Group

Ever created a bunch of stored procedures for testing purposes and went to drop them but couldn't remember all the names you created? A way to avoid this is to group multiple stored procedures under a single name. The following is the syntax for grouping:
create procedure <procname>1
as
 ....
 ....
 GO
create procedure <procname>;2
as
 ....
 ....
 GO

Example:
create procedure <test>;1
as
 ....
 ....
 GO
create procedure <test>;2
as
 ....
 ....
 GO
The number assigned for each stored procedure will vary from 1 TO 32767. If you want to execute the stored procedure:
 
exec test;1
exec test;2 ... etc
Drop all stored procedures using the drop procedure test.

Note: This tip works for all MS SQL 2000 flavors.

Jaya Nehru Kumar
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
Thanks for your registration, follow us on our social networks to keep up-to-date