The hospital database is a relational database since it is made up of tables. The records stored in these tables in the form of rows and columns. Each row in table stores specific data; the data are called the attributes(Pratt & Last, 2014).
The entities for this database will be the Physician table and patient table.
Physician ( staffID , LastName,FirstName, emailAddr, DOB,postalCode, salary)
Patient ( PatID , LastName,FirstName age, sex, weight, DOB )
In the above shorthand representation, the underlined attributes are the primary keys for each relation. A primary key is a unique identifier within each table, which uniquely identifies an attribute .in case we are to query some data within a database. Nonetheless, a primary key can be used to linked two relations. This feature allows users to views the attribute of a certain entity when we wish to view it(Pratt & Last, 2014). A primary that is used to link another relation is referred to as a foreign key in the other table, but a primary key in its relation.
Delegate your assignment to our experts and they will do the rest.
For this database, the foreign key will be the PatID .
PatID will be used to link the physician relationship with that of patient relation in that when the physician is to serve a patient, and the physician will query the patient details by just referring to the foreign key. To access data from tables, we use commands to know queries. A query is used to fetch records of a specific entry, as requested. There are different tools used to query records stored in the database.
Moreover, at the Hospital database, there are one too many relationships between the physician table to that of the patient table. It implies that one physician can be linked or serve more than one patient. Also, for data to be stored consistently within the Hospital database, they have to be normalized to remove conflict or repeated entries. As it clear that entries in every row of a database have to be
References
Pratt, P. J., & Last, M. Z. (2014). Concepts of Database Management . Boston, MA: Cengage Learning.
unique (Pratt & Last, 2014).