Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction –All information systems create, read, update and delete data. This data is stored in files and databases. Files are collections of similar.

Similar presentations


Presentation on theme: "Introduction –All information systems create, read, update and delete data. This data is stored in files and databases. Files are collections of similar."— Presentation transcript:

1

2 Introduction –All information systems create, read, update and delete data. This data is stored in files and databases. Files are collections of similar records. Databases are collections of interrelated files. –The key word is interrelated. –The records in each file must allow for relationships (think of them as ‘pointers’) to the records in other files. –In the file environment, data storage is built around the applications that will use the files. – In the database environment, applications will be built around the integrated database.

3 Fields Fields are common to both files and databases. –A field is the implementation of a data attribute. Fields are the smallest unit of meaningful data to be stored in a file or database.

4 Fields (cont.) There are four types of fields that can be stored: primary keys, secondary keys, foreign keys, and descriptive fields. –Primary keys are fields whose values identify one and only one record in a file. –Secondary keys are alternate identifiers for an database. A single file in a database may only have one primary key, but it may have several secondary keys.

5 Fields (cont.) –Foreign keys are pointers to the records of a different file in a database. Foreign keys are how the database ‘links’ the records of one type to those of another type. –Descriptive fields are any other fields that store business data.

6 Records Fields are organized into records. Like fields, records are common to both files and databases. –A record is a collection of fields arranged in a predefined format.

7 Files and Tables Similar records are organized into groups called files. –A file is the set of all occurrences of a given record structure. In database systems, a file corresponds to a set of similar records; usually called a table. –A table is the relational database equivalent of a file.

8 Databases –Databases provide for the technical implementation of entities and relationships. –The history of information systems has led to one inescapable conclusion: Data is a resource that must be controlled and managed! –Out of necessity, database technology was created so an organization could maintain and use its data as an integrated whole instead of as separate data files.

9

10 Relational Database Management Systems Relational Database Management Systems : Relational databases implement data in a series of tables that are ‘related’ to one another via foreign keys. –Files are seen as simple two-dimensional tables, also known as relations. –The rows are records. –The columns correspond to fields.

11

12 The query language of most relational databases is called SQL (which stands for Structured Query Language). –SQL supports not only queries, but complete database creation and maintenance. –A fundamental characteristic of relational SQL is that commands return ‘a set’ of records, not necessarily just a single record (as in non- relational database and file technology).

13 –SELECT specific records from a table based on specific criteria (e.g. SELECT CUSTOMER WHERE BALANCE > 500.00) –PROJECT out specific fields from a table (e.g. PROJECT CUSTOMER TO INCLUDE ONLY CUSTOMER_NUMBER, CUSTOMER_NAME, BALANCE) –JOIN two or more tables across a common field – a primary and foreign key (JOIN CUSTOMER AND ORDER USING CUSTOMER_NUMBER)

14 Query by example

15


Download ppt "Introduction –All information systems create, read, update and delete data. This data is stored in files and databases. Files are collections of similar."

Similar presentations


Ads by Google