It online Exam

5. Database Concepts

Lesson No. 5 Database Concepts using LibreOffice Base

 

Textbook Exercises

Fill ups

1. __________ is a collection of related data. 

Ans. Database

2. Queries are used to _______ information from database.

Ans. retrieve

3. The representation of data in printed form is called as __________

Ans. Report

 

True or False

1.      Form is used to collect the data from the user. TRUE

2.     Menu bar is present below Title bar. TRUE

3.     Columns are called as records. FALSE

 

MCQ ( select 1 correct answer)

1.  Rows in Base are called as _____ 

Ans. Records

2.  File extension of Base is _______ 

Ans. .odb

 

Answer in Brief

1. Define Database

Ans. Database is a collection of related data items stored in an organized manner. A database consist of different objects like table, query, form and report.

2. What is a query?

Ans. A Query is a question asked within the database environment. Query is used to retrieve records from the table. Query displays subset of data contained in various tables of database.

3. Define Report.

Ans. The presentation of information in an organized and readable format as per the user’s requirement known as report. Report is the representation of data in printed form. Various complex reports can be generated that can help in taking decisions by the management.

4. Explain working area of Base.

Ans. The area below the standard toolbar is called as working area. It is divided into two panes – Left pane and right pane. Left pane displays name of database objects like tables, queries, forms and reports. Right pane display activities related to that particular object.

 

Match the following

1.  Query                              -                       Retrieve data from database.

2.  Report                             -                       printed form of data.

3.  Form                                -                       Collect information from user.

4.  Table                                -                       Collection of related data.

 

 


 

Additional Exercises

 

Answer in brief

5.  Define Data and Information

Ans. Data means all kinds of facts, figures and details related to people, places, things or events.

Information is the result obtained from processing.

 

6. What is a Table?

Ans. Table is a basic unit for storing data in database. Tables are organized in the form of rows and columns. User can insert, edit and delete records from table.

 

7. Define Entity

Ans. An entity is any real world object about which data is to be stored. Each entity has collection of attributes associated with it.

An attribute is the property of entity. It is stored in the form of columns. Example – Student entity has attribute s like roll number, name, address, standard, date of birth, etc.

 

8. List the data type available in Base.

Ans. The data types can be divided into categories as alphanumeric, numeric, calendar and binary type.

 

Numeric data types

Alphanumeric data types

Calendar(Date and Time) data types

Binary data types

TINYINT

CHAR

DATE

Image(LONGVARBINARY)

BIGINT

VARCHAR

TIME

VARBINARY

NUMERIC

VARCHAR_IgnoreCase

TIMESTAMP

BINARY

DECIMAL

 

 

BOOLEAN

INTEGER

 

 

 

SMALLINT

 

 

 

FLOAT

 

 

 

REAL

 

 

 

DOUBLE

 

 

 

 

9. What is a Form?

Ans. A form is an object which allows entering the data and editing or deleting existing data in the table. Form is used to collect the data from the user. It consists of format, style and widgets like radio button, list boxes that provides easy and systematic way to insert records in the table.

 

10. What is Data model?

Ans. Data model defines how the logical structure of a database is modeled. Data model defines how data is connected to each other and how they are processed and stored inside the system.

There are types data model such as relational data model, network data model, hierarchical data model, object-oriented data model, entity relationship data model, etc.

 

11. What is Relational Data Model?

Ans.  In relational data model, data in a database is stored in structured format, using rows and columns called tables. It is relational because the values within each table are related to each other. Tables may also be related to other tables. In relational model, tables are called relations that store data for different columns.

 

12. Define Attribute, Domain, Tuple, Degree, Cardinality

Ans.

Attribute – Characteristic or parameters for which data are to be stored in a relation. The columns of a relation are the attributes which are also referred as fields.

Domain – It is a set of values from which an attribute can take a value in each row. A data type is used to specify domain for an attribute.

Tuple – Each row of data in a relation (table) is called a tuple. A tuple is a relationship between the n related values.

Degree – The number of attributes in a relation is called the Degree of the relation.

Cardinality – The number of tuples in a relation is called the Cardinality of the relation.

13. Define the following

a) Candidate Key – A relation(table) can have one or more attributes(columns) that takes unique values. The attributes can be used to uniquely identify the tuples in the relation are called candidate keys.

b) Primary Key – The attribute used to uniquely identify the tuples(rows) in relation is called the primary key of that relation.

c) Foreign Key – A foreign key is used to represent the relationship between two relations(tables). A foreign key is an attribute whose value is derived from the primary key of another relation.

 

14. Explain the types of relationships in relational database design.

Ans. The types of relationships are as follows :

a) One-to-One (1:1) –  In one-to-one relationship, a row in table A can have only one matching row in table B.

b) One-to-Many (1:M) – In one-to-many relationship, a row in table A can have  one or many matching rows in table B.

c) Many-to-Many (M:M) – In many-to-many relationship, a row in table A can have  many matching rows in table B and vice versa.

 

 

 

 

No comments:

Post a Comment