Hi All,
Is there a way to get the Data Definition Library for a
Database? I need to send it to my parent Corporation.
Thanks,
JoeThere are a number of ways to generate the T-SQL code to recreate your
database. Here is an article that might help:
http://www.dbazine.com/larsen4.shtml
--
----
----
--
Need SQL Server Examples check out my website at
http://www.geocities.com/sqlserverexamples
"JOE" <anonymous@.discussions.microsoft.com> wrote in message
news:2b68501c468f4$50d93e60$a601280a@.phx.gbl...
> Hi All,
> Is there a way to get the Data Definition Library for a
> Database? I need to send it to my parent Corporation.
> Thanks,
> Joe|||Hi,
Ope Enterprise Manager -- Expand the database-- Right click above the
database you need the DDL, Select "Alltasks" and click "Generate SQL Script"
and select options you require and click OK. THis
will generate the DDL script for that database.
You can save this as a .SQL file and send to parent corporation.
Thanks
Hari
MCDBA
"JOE" <anonymous@.discussions.microsoft.com> wrote in message
news:2b68501c468f4$50d93e60$a601280a@.phx.gbl...
> Hi All,
> Is there a way to get the Data Definition Library for a
> Database? I need to send it to my parent Corporation.
> Thanks,
> Joe|||Thank you Gregory,
I know how to generate the SQL Script for a DB. I was
wondering if there was a tool or a process to list all
table relationships, indexes and triggers.
Thanks again,
Joe|||This is a multi-part message in MIME format.
--=_NextPart_000_00DB_01C468C7.F0F8E300
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Have you tried the Database Diagram Wizard. If not this wizard should =be able to build you a picture of all the tables and will drawlines to =represent the foreign key relationships. Is this what you are looking =for? You might also consider looking at the =INFORMATION_SCHEMA.TABLE_CONSTRAINTS view
As far as the triggers are concerned you could use SQL-DMO you could =process thru the table object and then through the trigger collection to =identify all the triggers.
Another option might for both might be to select to script all tables, =but then only select the check boxes that generate triggers and foreign =key constraints.
-- ----=----=--
Need SQL Server Examples check out my website at =http://www.geocities.com/sqlserverexamples
"Joe" <anonymous@.discussions.microsoft.com> wrote in message =news:2bdfe01c468f8$502ed0c0$a501280a@.phx.gbl...
> Thank you Gregory,
> > I know how to generate the SQL Script for a DB. I was > wondering if there was a tool or a process to list all > table relationships, indexes and triggers.
> > Thanks again,
> Joe
--=_NextPart_000_00DB_01C468C7.F0F8E300
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
&
Have you tried the Database Diagram =Wizard. If not this wizard should be able to build you a picture of all the =tables and will drawlines to represent the foreign key relationships. Is this =what you are looking for? You might also consider looking at the INFORMATION_SCHEMA.TABLE_CONSTRAINTS view
As far as the triggers are concerned =you could use SQL-DMO you could process thru the table object and then through the =trigger collection to identify all the triggers.
Another option might for both might be =to select to script all tables, but then only select the check boxes that generate =triggers and foreign key constraints.
-- ---=----=--
Need SQL Server Examples check out my =website at http://www.geocities.com/sqlserverexamples
"Joe" wrote in message news:2bdfe01c468f8$502ed0c0$a501280a@.phx.gbl...> Thank you =Gregory,> > I know how to generate the SQL Script for a DB. I was => wondering if there was a tool or a process to list all > table relationships, indexes and triggers.> > Thanks =again,> Joe
--=_NextPart_000_00DB_01C468C7.F0F8E300--|||Thank you very much for this info!
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment