SQL Server >> Scripting a database

by Sm9obg » Mon, 13 Sep 2004 06:25:03 GMT

I would like to run a job to script a database in case of the database being
deleted. Is there a command to script a databse?


SQL Server >> RE: Scripting a database

by TmlnZWwgUml2ZXR0 » Mon, 13 Sep 2004 07:17:08 GMT


http://www.nigelrivett.net/DMOScriptAllDatabases.html

But you should really rely on backups for that.






SQL Server >> Scripting a database

by Hari Prasad » Mon, 13 Sep 2004 11:44:27 GMT

Hi,

Why dont you backup your database daily once using the below command.

backup database <dbname> to disk='d:\backup\dbname.bak' with init

This backup fine can used to restore the entire data and objects incase ur
database is corrupted or deleted.

Thanks
Hari
MCDBA







RE: Scripting a database

by U2FsZWVtIEhha2FuaQ » Mon, 13 Sep 2004 13:41:05 GMT

You may want to try SCRPTXFR tool that comes along with SQL Server 2000.
This can help you script out database or any objects you want.

HTH
XXXX@XXXXX.COM






Scripting a database

by Tibor Karaszi » Mon, 13 Sep 2004 23:54:59 GMT


Similar Threads

1. Scripting entire database.

2. How to set the Script Manager Database Connection String - SQL Server DTS

3. Scripting a Database

All,

Is there a setting in Enterprise Manager, which controls 
the order in which items are scripted (triggers, tables, 
stored procedures, and functions)?  The reason I ask is 
that our developers script our production database into a 
large file.  We then compare the content of the script 
with the source control version to verify that the 
contents of the file are the same +/- the changes that 
were made in between scripting.  The issue is that 
depending upon the developer scripting the database, the 
order of the items in the script is different.


Thanks,

Ronald Cotton

4. Don't Run Script If Database Exists - SQL Server

5. How to generate 'full' scripts for database objects?

Hi

Is it possible to generate full create table scripts that include default
values etc in addition to the default?  I find default values very useful,
and often have to pass sql scripts to others for deployment.

-Brian


6. Scripting of database objects in SQL 2005 - SQL Server

7. slq 2005 - scripting out database objects to SEPARATE files

Hi,
I tried the script wizard (sql 2005) to script out database tables and 
stored procedures, but could not figure out how to create SEPARATE files 
(one per object) as that was the case with sql 2k and prior versions.

Thanks 


8. Run the script if database does not exists - SQL Server