A company has a database to keep employees' daily
attendance records. A record in this attendance database
has the following information: employee-id, month-date-year, time-in, time-out.
The company decides to give an annual bonus check to the employee according
to the following formula: 10% salary bonus for no absence,
5% bonus for less than 5 days of absence, and 2% bonus for more
than five days of absence. We want to design the data flow diagram
for this application and then covert the data flow diagram
into an information structure.
The DFD looks like this:
----------
---------- |compute | -----------
|compute |-------------->|10%raise|------------->| print |
|days of | no absence ---------- | | ----------
|absence | | bonus |<-->|Employee
|of an | ---------- | | |database
|employee| |compute | | check | ----------
| by |-------------->|5% raise|------------->| |
|reading | < 5 days ---------- | for an |
|from the| | |
|database| ---------- |employee |
| and |-------------->|compute | | |
|compile | >= 5 days |2% raise|------------->| |
| stats | ---------- -----------
----------
|
|
-----------
|Attendance
|Database
-----------