Wednesday, March 28, 2012

Relationship in Access, what about SQL Server 2000?

Hello,

In Microsoft Access, there is a feature to create relationships between tables. When creating these relations, you have the option to:

1. Establish the relation type. For example, 1 to many (primary key to foreign key)

2. Enforce referential integrity

3. Allow cascading updates

4. Allow cascading deletions

5. View these relations in a nice diagram

Does SQL Server 2000 contain this functionality? If so, where is this found in the Enterprise Manager? If not, what is the alternative to this very useful feature found in Access?

Thanks You For Any Help!

In Enterprise Manager select your Db, select Diagrams (Create One if neccessary - use auto) and then use drag and drop with the key fields to create the relationships. You will get a nice popup with various options such as cascading etc.|||

You can also use the design view or sql command to do this.

If you want to use the design view to add relationship, do the followings

Open EM|||

HIdefyant_2004

Sql server gives to us many features and there are many ways to create relationship between two tables. Here is the common way to create

1. Open EM

2. Right_click on Diagrams

3. Select New Database Diagram...

4. Next

5. Select the tables you want to create relationship

6. Next step...like Access

Cheers!

No comments:

Post a Comment