"simon" wrote in message
> Hello,
> i am looking to make a full scripted backup of my sql server 2000
> database
> using various free tools, i can easily export the table structures and
> stored procs into my script, but i have not found anything to help
> with:
> - indexes
> - users/logins
> - roles
> - functions
> - jobs
> (anything else you can suggest)
>
> have done many searches for utils or system tables that holds this
> info, have not been successful.
> could you please help me with how i can extract this info into scripts
> if needed, i don't mind writing a proc that will gen the scripts, but
> do need help with what tables hold this info
>
> thanks very much for you help..... kinda desperate....
>
Enterprise Manager does it all.
Right-Click on the DB. Select All Tasks -> Generate SQL Scripts...
Click the button Show All.
Now examine all tabs (General, Formatting and Options). You will find
Triggers, Logins, Indexes and even DB itself. You can script them into
separate files per object or create just one big file. You can choose
different formatting options (e.g. to include Drop statements).
The only thing - jobs are scripted separately, because they are not part of
particular DB. You can script them in similar way by clicking on Job node in
the treeview.
You can automate the process yourself using DMO - well, it's gonna take some
time.
Dmitriy.