IP Class 12 Tutorial

An organization wants to create a database EMPDEPENDENT to maintain following details about its employees and their dependent.
EMPLOYEE (AadharNumber, Name, Address, Department, EmployeeID)
DEPENDENT (EmployeeID, DependentName, Relationship)

a) Name the attributes of EMPLOYEE, which can be used as candidate keys.b) The company wants to retrieve details of dependent of a particular employee. Name the tables and the key which are required to retrieve this detail.c) What is the degree of EMPLOYEE and DEPENDENT relation? Ans: (a) AadharNumber, EmployeeID (b) To retrieve the […]

An organization wants to create a database EMPDEPENDENT to maintain following details about its employees and their dependent.
EMPLOYEE (AadharNumber, Name, Address, Department, EmployeeID)
DEPENDENT (EmployeeID, DependentName, Relationship)
Read More »

The school canteen wants to maintain records of items available in the school canteen and generate bills when students purchase any item from the canteen. The school wants to create a canteen database to keep track of items in the canteen and the items purchased by students. Design a database by answering the following questions:

a) To store each item name along with its price, what relation should be used?Decide appropriate attribute names along with their data type. Each item and its price should be stored only once. What restriction should be used while defining the relation?Ans: We will create new relation BILL to keep bill details as per the

The school canteen wants to maintain records of items available in the school canteen and generate bills when students purchase any item from the canteen. The school wants to create a canteen database to keep track of items in the canteen and the items purchased by students. Design a database by answering the following questions: Read More »

A school has a rule that each student must participate in a sports activity. So each one should give only one performance for sport activity. Suppose there are five students in a class, each having a unique roll number. The class representative has prepared a list of sports preferences as shown below. Answer the following:

a) Roll no 24 may not be interested in sports. Can a NULL value be assigned to that student’s preferences field? Ans: Yes, a NULL value can be assigned. b) Roll no 17 has given two preferences sports. Which property of relational DBMS is violated here? Can we use any constraint or key in the

A school has a rule that each student must participate in a sports activity. So each one should give only one performance for sport activity. Suppose there are five students in a class, each having a unique roll number. The class representative has prepared a list of sports preferences as shown below. Answer the following: Read More »

What are the limitations of file system that can be overcome by a relational DBMS?

The limitation if file systems that can be overcome by a relational DBMS are: Data Redundancy: redundancy means repetition of same data in different tables. Redundancy leads to excess data storage and may cause data inconsistency. Data Inconsistency: When same data is managed differently in different places leads to data inconsistency. Data inconsistency creates unreliable

What are the limitations of file system that can be overcome by a relational DBMS? Read More »

Differentiate between Primary key and Foreign key

Primary Key Foreign Key It identifies the each record in a table uniquely. It maintains the relation between two tables. A foreign key is primary key in another related table. A table can have only one Primary key. A table can have more than one Foreign key. Primary key cannot have NULL values. Foreign key

Differentiate between Primary key and Foreign key Read More »

Differentiate between Database state and database schema

Database Schema Database State Database Schema represent overall design of the database. Database state represent current state of data in database. Database schema is changed ocassionally Database state is changed frequently Initially when defining a database, only Database schema is specified Initially when defining a database, database state is empty state.

Differentiate between Database state and database schema Read More »

Why foreign keys are allowed to have NULL values? Explain with an example.

Foreign Key is used to represent the relation between two tables. Because in the field with Foreign key attribute data comes from Primary key field in another related table and so Foreign key are allowed to have Null Values if it not the part of Primary key field of the related table. For example- Here

Why foreign keys are allowed to have NULL values? Explain with an example. Read More »

1. Give the terms for each of the following:
Collection of logically related records.

a) Collection of logically related records.b) DBMS creates a file that contains description about the data stored in the database.c) Attribute that can uniquely identify tuples in a relationd) Special value that is stored when actual data value is unknown for an attribute.e) An attribute which can uniquely identify tuples of the table but is

1. Give the terms for each of the following:
Collection of logically related records.
Read More »

error: Content is protected !!