Page 243 - DCAP405_SOFTWARE_ENGINEERING
P. 243

Software Engineering




                    Notes         14.1 Data Models

                                  To design any system, we require a mathematical model. Similarly, for DB Systems there are
                                  several models being used as given below:

                                       Hierarchical Model
                                       Network Model

                                       Relational Model
                                       Object-relational Model
                                       Object Model
                                  Out of all the above models, the Relational Model is used by most of the database management
                                  packages, including Oracle, Ingres, Sybase, etc.
                                  Hierarchical, Network, and Relational Models


                                  Data pertaining to the real world applications are not isolated entities rather they are related to
                                  each other in many ways – simple and complex. A data model captures the essence of relation
                                  with the data items. Various data models view data and their relationships in different ways. In
                                  the following section we discuss the first two conventional data models – Hierarchical and
                                  Network – in reverse order.
                                  Relational Model


                                  The model was first introduced by Tod Codd of IBM Research in 1970. It uses the concept of a
                                  mathematical relation. Hence, the database is considered as a collection of relations. A relation
                                  can be thought as a table of values, each row in the table represents a collection of related data
                                  values. In relational model terminology, a row in the table is called a tuple and a column header
                                  is called an attribute.
                                  A relation schema R, denoted by R(A ,...,A ) , is made up of a relation name R and a list of
                                                                  1   n
                                  attributes A ,...,A . The domain of A , denoted by dom(A ) is the set of all the possible values this
                                            1   n              i               i
                                  attribute may take.
                                  A relation schema that describes a relation R is called the name of this relation. The degree of a
                                  relation is the number of attributes in its relation schema.


                                       !
                                     Caution  A record contains information regarding a single person or thing of interest.

                                  A field stores data regarding a particular aspect of that person or thing. The organization is
                                  illustrated below:

















          236                               LOVELY PROFESSIONAL UNIVERSITY
   238   239   240   241   242   243   244   245   246   247   248