Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Q.1. Explain the difference between following terms: a) Schema and Instance b) P

ID: 669292 • Letter: Q

Question

Q.1. Explain the difference between following terms:

a) Schema and Instance

b) Physical and Logical data independence

c) Weak and a Strong entity set

Q.2. Explain the following terms:

a) Atomicity

b) DML

Q.3. Write an expression in the relational algebra to express each of the following queries:

a) Find the names of all employees who live in “Miami” and whose salary is greater than

$100,000

b) Find the details of a person whose ID is “11111”

Q.4. Consider university database with the following features:

a) Students have an ID number, a name, a date of birth, and a degree program.

b) Departments have a department number, a department name, and a main office.

c) Course have a course name, description, course number and offering department.

d) Each student has one major department in which they are working on their degree.

Furthermore, Students may take different courses.

Draw an ER diagram, showing the relations described above.

Explanation / Answer

This question has multiple subparts. Please post one more question.

1

a) An instance is a set of processes and a shared memory segment (SGA).An instance may mount and open any database — however it may only open a single database at any time.

A schema is the container of the schema objects so all the tables, views, procedures, packages, views etc. reside in the schema. There can be multiple schemas per database.

b)

Logical data is the data about the database implemented.It basically stores information about how data is managed inside. For example, a table (relation) stored in the database and all its constraints, applied on that relation.

Logical data independence is a kind of mechanism, which liberalizes itself from actual data stored on the disk. If we do some changes on table format, it should not change the data residing on the disk.

Physical data independence on the other hand is the ability to change the physical data without impacing the schema/structure of the databse.

For example, if we want to changet the storage system for our architectures i.e if we want to replace hard-disks with SSD it should not have any impact on the logical data or schemas.

c)

Weak entity set is the one where the set does not have sufficient attributes to form a primary key is known as Weak entity set.

The entity set where primary key is defined is strong entity set.

2)

a) Atomicity is one of the acid properties of the in the database where a series of database operation will occur together or nothing will occur.

b) DML or Data Manipulation language is a set of commands in a computer programming language used for selecting, inserting, deleting and updating data in a database

3)

a)

select * from employees where city = "miami" and salary > 10,000