Tuesday, March 27, 2012

Database clone

Hi :
If I want to do the follow :
I create 2 database in localhost
one is dev_db
one is clone_db
Where dev_db have data in the database, but clone_db is just a data
structure but need to synchronize with dev_db schema.
If I add table in dev_db , clone_db will auto add same table structure from
dev_db.
If I change the column (include add, change data type), clone_db will auto
to change.
If I change the script (both view, stored procedure, view, user define
function and trigger), , clone_db will auto to change.
Base on above situation, can sql server 2K do this ?
and how to set ?
Thanks for your help
SQL Server can not do this natively but you can find lots of 3rd party tools
that will compare two db's and give you a script to make them the same.
Have a look at www.red-gate.com
Andrew J. Kelly SQL MVP
"Tom" <pclan@.tomgroup.com> wrote in message
news:ebItLZNYFHA.1796@.TK2MSFTNGP15.phx.gbl...
> Hi :
> If I want to do the follow :
> I create 2 database in localhost
> one is dev_db
> one is clone_db
> Where dev_db have data in the database, but clone_db is just a data
> structure but need to synchronize with dev_db schema.
> If I add table in dev_db , clone_db will auto add same table structure
> from
> dev_db.
> If I change the column (include add, change data type), clone_db will auto
> to change.
> If I change the script (both view, stored procedure, view, user define
> function and trigger), , clone_db will auto to change.
> Base on above situation, can sql server 2K do this ?
> and how to set ?
> Thanks for your help
>
|||Hi Tom,
Another tool that can do this for you is DB Ghost (www.dbghost.com). Not
only is it a great tool for comparing and synchronizing databases it is
also possible to run it from the command line (and therefore via a standard
scheduled task) to fully automate your process. For this type of
functionality DB Ghost is significantly less expensive than Red Gate as
they require you to buy their toolkit product to run the compare engine in
non GUI mode.
Regards,
Malc

No comments:

Post a Comment