Database Relationships and Integrity


Added on  2019-09-16

2 Pages813 Words269 Views
Transcript of Copy of Unit 18 P1Entities can be related to each other through the Primary Key and Foreign Key because, instead of typing the entities all over again you can use a key on another part of a database and link the entities through it. What are Relationships? What do they do?What is a Primary Key?What advantages are there with using a database1. Databases save time. Retrieving a single record, which may take several minutes of digging in a paper-based filing system, can be done with just a few clicks in a computerized database. Merging database records with documents makes producing paper reports almost instantaneous2. Databases give you lots of different ways to look at your data. A request for a specific answer or list from your database called a "query" can take just a minute or two to write, as opposed to hand-collating data records or sorting and resorting a spreadsheetUnit 18 P14. Well organized system which enable you to search for a particular name in the most quickest wayA primary key is a unique identifier for a database record. For example, When a table is created one of the fields is assigned as the primary key. While the primary key is often a number, it may also be a text field or other data type.What is a Foreign Key?A Foreign Key is a key that is a column of groups or a group of columns in a relational database table that provides a link between data in two table. For example you may link a ID (Primary Key of a section) to another part of a database and then itwill make a copy of an id and will then be transferred as a Foreign key.A one-to-many relationship occurs when a parent record in one table can potentially reference several child records in another table. In a one-to-many relationship, the parent is not required to have child records; therefore, the one-to-many relationship allows zero child records, a single child record or multiple child records. The important thing is that the child cannot have more than one parent record.
Database Relationships and Integrity_1

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents

Systems Analysis and Database Design

Diploma of Information Technology: Assessment Task 1

Entity Relationship Diagram in Library Management System

Conceptual and Logical Database Model

Characteristics of Hierarchical, Network, and Relational Database Models