sql

How to delete relationships in SQL server

Developers delete a relationship when they no longer want to relate columns in two related tables. When they redesign tables, it is often necessary to delete relationships and then recreate them after their new design is complete. When Developers working with SQL Server “Denali”, MS SQL Server 2008 R2 and MS SQL Server 2005 want to …

Learn more

How to create a foreign key from GUI in SQL server

Developers create a relationship between two tables when they want to associate rows of one table with rows of another.  They can create a foreign key relationship in Table Designer, by following the next steps:

1. In Object Explorer, right-click the table that will be on the foreign-key side of the relationship and …

Learn more

How to assign an XML Schema Collection to a column in SQL server

Columns that use the xml data type can have the XML values validated against an XML schema collection. The schema collection must exist in the database before developers modify the table. If they create a new schema while modifying the table definition, the schema collection list will not include the new collection. When developers working with SQL Server …

Learn more

How to copy data from one table to another in SQL Server

When developers working with SQL Server “Denali”, MS SQL Server 2008 R2 and MS SQL Server 2005 want to copy data from one table to another, they should follow the next steps:

1. Follow the steps described in the article: How to copy column definitions from one table to another in SQL Server. …

Learn more

How to open a table in Table Designer

Developers can open in SQL Server “Denali”, MS SQL Server 2008 R2 and MS SQL Server 2005 Table Designer to view or edit its structure, by following the next steps:

1. From the View menu, click Object Explorer.

2. In Object Explorer, right-click the database table they want to open and click …

Learn more

How to open a new table in Table Designer

The Table Designer is a visual tool that allows developers to design and visualize database tables to which they are connected. Developers use Table Designer to create, edit, or delete tables, columns, keys, indexes, relationships, and constraints. When developers working with SQL Server “Denali”, MS SQL Server 2008 R2 and MS SQL Server 2005 want to …

Learn more

How change the font color, size and style in diagrams

When developers working with SQL Server “Denali”, MS SQL Server 2008 R2 and MS SQL Server 2005 want to change the font color, size, and style in diagrams, they should follow the next steps:

1. On the Tools menu, click Options.

2. Expand Environment, and then click Fonts and Colors.

3. In the …

Learn more

How to copy a table from another database diagram

Copying a table from one database diagram to another diagram adds a reference to the table in the second diagram. The table is not duplicated in developers’ database. For example, if they copy the clients table from one database diagram to another, each diagram references the same clients table in the database. When Developers working with …

Learn more

How to delete a database diagram in Object Explorer

When Developers working with SQL Server “Denali”, MS SQL Server 2008 R2 and MS SQL Server 2005 want to delete a database diagram, they should follow the next steps:

1. In Object Explorer, expand the Database Diagrams folder.

2. Right-click the database diagram that they want to delete.

3. Choose Delete on the …

Learn more