Page 159 - DMGT505_MANAGEMENT_INFORMATION_SYSTEM
P. 159
Management Information Systems
Notes In the above example, the use of three basic operators has been explained. However, it may be
noted that SQL does not use the SELECT, PROJECT and JOIN formats at the syntactic level, rather
it follows a generic format consisting of three sub-commands as follows.
SELECT Filed list
FROM List of tables
WHERE Condition
Example: We want to know the name of course(s) where the number of students are less
than 21 from our earlier database stored as relation course (Table 8.3).
SLECT CNO, CTITLE, CREDITS, STDNO
FROM Course
WHERE STDNO <21
This will produce the report as given below.
Table 8.6
SNO CTITLE CREDITS STDNO
CS406 Information 3 20
Technology
CS303 Strategic Systems 4 20
Information from two different tables may be extracted by using dot (.) notation as shown below.
SELECT CTITLE, NAME
FROM Course, Teacher
WHERE Course.TCODE = Teacher.TCODE;
SQL can also perform many other functions that include sorting (ordering), group functions of
averaging, summing, locating maximum and minimum values, counting the numbers in a
column, etc.
Task Discuss relational model with suitable example.
8.3.4 Data Modelling
Data modelling is the analysis of data objects that are used in a business or other context and the
identification of the relationships among these data objects. A data model is a collection of
logical constructs used to represent the data structure & the data relationships found within the
database. The two different categories of data models are:
1. Conceptual Models: Focus on the logical nature of the data representation. They are
concerned with what is represented rather than how it is represented. The Entity-
relationship model is a popular conceptual model.
2. Implementation Models: Place the emphasis on how the data are represented in the database
or on how the data structures are implemented. The examples are:
(a) Hierarchical
154 LOVELY PROFESSIONAL UNIVERSITY