Sunday, September 8, 2013

P3C6: Databases

Databases - Outlines

  1. A flat file consists of a large number of records each of which comprises a number of fields.
  2. Each field has its own data type and holds a single item of data.
  3. Limitations of flat-file systems:
    • separation and isolation of data
    • duplication of data
    • data dependence
    • data inconsistencies
    • difficulty in changing applications programs
  4. Relational databases store data in tables.
  5. Normalization is a set of formal rules that must be followed after a set of table is designed.
  6. Normal forms (NF):
    • 1 NF: It doesn't have a repeated group of attributes
    • 2 NF: There are no non-key fields attributes which are dependent on only part of the primary key
    • 3NF: There are no dependencies between non-key attributes
  7. An entity - relationship (E-R) diagram shows the entities in the database and the relationships between them.
  8. A relational database gives the following advantages over flat files:
    • Data are contained in a single software application.
    • Duplication of data is minimized.
    • Data inconsistency is reduced.
    • The volume of data is reduced leading to faster searching and sorting of data.
    • Data structures remain the same even when tables are altered.
    • Existing programs don't need to be altered when a table design is changed or new tables created.
    • Queries and reports can be set up quickly.
  9. A primary key is used to uniquely identify a record or row in a table.
  10. A foreign key attribute links to a primary key in a second table.
  11. A secondary key is used to get fast access when searching on this attribute.
  12. Different categories of user can see different views of the data - only what is needed for their job.
  13. Terminals in public areas may be refused access to sensitive data, even if the user has access.
  14. A DBMS (Database Management System) is a piece of software that provides the following facilities:
    • a data definition language (DDL) that the database designer uses to define the tables of the database
    • a data dictionary that contains all design information
    • a data manipulation language (DML) for inserting, selecting, updating and deleting data records
    • backup of the database data
    • control of multi-user access to the data.
  15. The DML and DDL used by all modern database software is Structured Query Language (SQL).

No comments:

Post a Comment