Copy entire database to another in ASP code?

Results 1 to 3 of 3

Thread: Copy entire database to another in ASP code?

  1. #1
    Join Date
    Dec 1969

    Default Copy entire database to another in ASP code?

    I need to create an "archive" function. After looking at all the data that I want to back up, I&#039;ve determined that I&#039;d be better off just copying the entire database to another name. The customer will only do this once a year, however, I&#039;d rather that they have the ability to "push the button" themselves. I&#039;m sure I can figure out how to do this using SQL Server&#039;s Enterprise Manager, but is there a way to do this sort of thing using ASP (or ASP.NET) code? Basically, I just want to copy the entire database (tables, relations, indexes, stored procedures and all) to another database with a different name. Any ideas?<BR><BR>Thanks,<BR>Jesse

  2. #2
    Join Date
    Dec 1969

    Default If you can do it with..

    .. Enterprise Manager, you can do it from script. Enterprise Manager just makes SQL calls.<BR><BR>Now, my suggestion - you should be able to do some kind of back with DTS. And, you can kick off the DTS job from ASP.

  3. #3
    Join Date
    Dec 1969
    Los Angeles, CA

    Default Too much work

    why waste time writing that, you have to make sure the tables are copied in order the relations built and the sp created and all that good stuff. Dont even bother. <BR><BR>What i would suggest is you archive on a regular basis just like a back up so you wont really have to do anything<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts