Tuesday, May 4, 2010

Database & SQL (Week 9)

This week, the lecture class was about the database and SQL. I remembered in my first semester, I took the database subject. Therefore, I have some knowledge about database and below is my summary for database and SQL.

According to Mannino (1990, cited in Databases Lecture Slides 2009), database is a collection of persistent data that can be shared and interrelated. There are some characteristics of data in databases:

  • Persistent (stored).
  • Inter-related.
  • Shared.

Moreover, Database Management System (DBMS) is a software system that enables users to define, create, maintain, and control access to the database (Connolly & Begg cited in Databases Lecture Slides 2009). Nowadays, there are many DBMS software in the marketplace (Databases Lecture slides 2009):

1. Enterprise DBMS
  • Oracle : dominates in Unix, strong in Windows.
  • SQL Server : strong in Windows.
  • DB2 : strong in mainframe environment.
  • Significant open source DBMSs : MySQL, Firebird, PostgreSQL.
2. Desktop DBMS
  • Access : dominates.
  • FoxPro, Paradox, Approach, FileMaker Pro

There are also some features of commercial DBMSs (Databases Lecture Slides 2009):

  • Database definition.
  • Non-procedural data access.
  • Application development.
  • Procedural language interface.
  • Transaction processing.

Furthermore, a relational database is a collection of tables (Databases Lecture Slides 2009). There are some terms in database:

  • Fields (columns).
  • Data types: CHAR, VARCHAR, INT, SMALLINT, FLOAT, DATE/TIME, DECIMAL, BOOLEAN.
  • Records (rows).
  • Tables.
  • Keys.
    • Superkey : column(s) with unique values.
    • Candidate key : minimal superkey.
    • Primary key : a designated candidate key and cannot contain null values
    • Foreign key : column(s) whose values must match the values in a candidate key of another table.
  • Relationships.
  • Relational database.
    • The ordering of rows has no significance.
    • The ordering of columns has no significance
    • Row must be unique
    • Cell values must be atomic
  • Relational Database Management System.

Structure Query Language (SQL) is a database computer language designed for managing data in relational database management system (RDBMS) (Wikimedia Foundation 2010). There are four basic operations in SQL (Weakley 2010):

  • Adding (inserting) data.
  • Finding (selecting) data.
  • Updating (modifying) data.
  • Deleting data.


References

No comments:

Post a Comment