Business and Productivity Software
Problem for Business and Productivity Software
Generic problem for all Business and Productivity Sof...

SQL Server 2000




By sankalp on Jan 17, 2008

" "
I am developing an accounting software in SQL Server 2000.
I want to create blank tables, stored procedures, user defined functions in new database which i am using in the last year's database.

I am using VB6.0 as front end tool and SQL Server 2000 as database.

My question is :
How programitically transfer Stored Procedures and UDF from last year's database to new year's database ?

Information : I created new year's database using SQL DMO, I created tables using script and executing it from stored procedure.

But I am not being able to tranfer the last year;s stored proc and udf to new year's database using vb code or vbscript code.

Please guide me through.

my email id is : aadityasankalp@yahoo.com

Solution #1

posted on Jan 17, 2008
Not Rated)

drewivan

Rank: Master 
Rating: 93%, 28 votes
An easy way to transfer objects (tables, user defined functions, stored procedures, etc.) is to use Enterprise Manager's "Generate SQL" feature. Use this process at your own risk. Doing it wrong could mess up your existing database.

1. In Enterprise Manager, right-click on the old database and choose "All Tasks" then "Generate SQL Script".
2. In the dialog that comes up, click "Show All" then select the checkboxes for "all stored procedures" and "all user defined functions". (You might also want to check some other boxes, depending on your exact situation.)
3. Click the "generate" button and save the script that it creates.
4. Run the script in the NEW database.

If you run the script in your OLD database, it may destroy your objects, and that would be very bad. Make sure you run the script in your NEW database. (While we're on this subject, it's a good time to mention that you should back up your database before you start this process, and you should make changes to a test system before migrating it to production.)

That should move your stored procedures and user defined functions over.

You can use a similar process to move tables, views, users, and other objects over as well.



Was this helpful?
Yes
No

Popular Solutions for Business and Productivity


Questions and Unsolved Problems for Business and Productivity


Answer
I have this issue and I'm under windows seven, my mail, contact etc, everything is ok except my... (More)

Answer
I am writing a user spreadsheet that requires a couple of drop down choices to prompt automatic cell... (More)

Answer
what is formula to use 5 point drop down list to prompt entry of cell value into specific location


Didn't find what you were looking for?

Describe your problem:

Select a Category:







Ask our Experts

 

Solve Your Problem Now!
Chat Live with an Expert
Chat Now
Browse popular Problems
More Common Problems
Most Common Problems for:
For Business and Productivity...:

Top Business and Pro... Experts

Rank: Guru Guru  

Solutions: 1451
Member Since: July 2009

Experience: I have owned a computer networking sales and service company.

Ask Me
Find more Business and Pro... Experts

Top Computer & Laptop Repair

(952) 890-7770
Zkarlo.com provides discount and used laptop parts...
Zkarlo.com

(877) 729-0812
We connect to your computer over the Internet to...
Remote Repair


       
Solve Your Problem Now!
Chat Live with an Expert
Chat Now

X
Continue
When the original poster rates a solution that was given to his own problem, that rating is locked!
X

Are you sure the solution content is Inappropriate?
   
Tech buddies can communicate directly to answer questions. Become a Tech Buddy and have direct access to your favorite expert for FREE!
Insert Link
Insert Image
Insert You-Tube clip
Insert List
Insert List
Spell Check

What is this?



Select