?
Solved

How do I export all of my stored procedures at once?

Posted on 2013-01-16
5
Medium Priority
?
364 Views
Last Modified: 2013-01-16
A client is creating a database that was created on my machine using the dbo.aspnet forms authentication tables and stored procedures. They currently have all the tables and the data in the tables how ever I've forgotten to get them the stored procedures that are created when .NET creates the aspnet tables and stored procedures that go with them. How can I quickly get all of the storprecedures to my client? Or do I have to copy and past them into a file, one at a time and send that? In other words, is that my only way of doing this?


Also, I noticed, in the "Stored Procedures" directory, that there is a sub set of stored procedures, in its own directory name "System Stored Procedures". Do I need those as well? And is there a particular order that the two groups of stored procedures need to be created in?
0
Comment
Question by:Michael Sterling
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 11

Assisted Solution

by:Simone B
Simone B earned 664 total points
ID: 38783398
Right click on the database where the procedures are located, and select Generate Scripts. This opens a wizard where you can select what you want scripted. Just select what you need from each prompt. Including select Stored Procedures from the Choose Object Types window. You can choose to create a script file, which you can then attach and send via email.

You shouldn't need the system sp's. They can be found in every SQL database.
0
 
LVL 27

Assisted Solution

by:Chris Luttrell
Chris Luttrell earned 1336 total points
ID: 38783406
In Management Studio, from the View Menu at the top go to Object Exporer Details and drill down to the Stored Procedure folder.  Then select all those you want together and right click and select Script Stored Procedure As ==> Create To ==> File Scripting_SP_to_File
0
 
LVL 1

Author Comment

by:Michael Sterling
ID: 38783468
@CGLuttrell: How do you select multiple strored procs at once? Shift + Click and Ctrl + Click don't work. Or are you saying that I just need to put all of them, individually, one at a time, in the same file? If so, that works but, I was hoping to be able to do it all in one or two clicks.
0
 
LVL 27

Accepted Solution

by:
Chris Luttrell earned 1336 total points
ID: 38783485
Object_Explorer_DetailsYou have to be in the Object Explorer Details window not the normal Object Explorer window that is the normal one on the left.  It will be bigger and where the querey window normally appears.
0
 
LVL 1

Author Closing Comment

by:Michael Sterling
ID: 38783650
Thank you.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article shows how to deploy dynamic backgrounds to computers depending on the aspect ratio of display
In the first part of this tutorial we will cover the prerequisites for installing SQL Server vNext on Linux.
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question