Notes - CH1 & 2 - DBMS - 19.11.2024
Notes - CH1 & 2 - DBMS - 19.11.2024
Database Management System (DBMS): The software that is used to create, update
and retrieve data is known as database management system (DBMS).
Examples of DBMS: MS Access, Open Office or LibreOffice Base, Oracle, Ingress,
MySQL.
Advantages of DBMS:
• Organised Storage
• Data Analysis
• Data Sharing
• Minimal Data Redundancy
• Data Consistency
• Increases Efficiency
• Increases Accuracy
• Increases Validity
• Security
Data Model: The structure of database is known as data model that describes the
manner in which data will be stored and retrieved.
Structure.
2. Network data model: In this model, multiple records are linked to same master
file.
3. Relational data model: In this data model, relationships between two or more
tables of the same database. It is the most commonly used database model.
2. Foreign Key – If a field of one table can be used to uniquely identify records of
another table, then that particular field is known as the foreign key.
Ex:- In Student Registration Table, ‘Enrolment_Number’ is the primary key and in
the Student Marks Table, ‘Roll_Number’ is the primary key, whereas
‘Enrollment_Number’ is the foreign key. This foreign key can be used to set a
relation between two tables
3. Candidate Key – All the field values that are eligible to be the primary key are
the candidate keys for that table.
4. Alternate Key – Out of the candidate keys, one or two are made as primary keys.
The others are the alternate keys.
Objects of an RDBMS:
1. Table - A table is a collection of logically related records or combination of rows
and columns
2. Forms - A form consists of text boxes, labels, radio buttons, list boxes, check boxes
etc. that give a user-friendly interface for entering data. The data entered through
the forms is stored in tables.
3. Query - It is a question asked from the database. A query is used to retrieve the
desired information from the database.
4. Reports - The output of a query may be displayed in the form of reports. The
usual result of the query is in the form of rows and columns.
4. Which of the following data models sets a relation between the two or more tables?
(a) Relational Data Model (b) Network Data Model
(c) Hierarchical Data Model (d) Connection Data Model
Data Types - The nature of data to be entered for various fields are of different types.
A data type refers to the type of data that will be stored in that particular field.
Example: names are stored in the form of text, age in numbers, fees in decimal
numbers, date of birth in date format and so on.
Some commonly used data types in RDBMS:
1. Text Data Types - The text data is a combination of letters, numbers or special
characters.
2. Numeric Data Types - Numeric data types consists of numbers. The numbers
can be integer or real numbers on which any type of arithmetic calculations can
be performed.
3. Currency Data Types - The currency data type indicates the monetary values
and can be stored using currencies of various countries.
For example $100, £ 500 or Rs. 25.50.
4. Date Data Types - This data type is used to indicate dates and time.
For example 12/25/2019, 08:45 AM.
5. Boolean Data Types - In Boolean data type there can be only two values - True
or False. This also can be given in multiple formats like Yes/No, True/False,
On/Off.
6. Binary Data Types - The Binary data type used to store digitized images and
sounds that comes as long string of zeros and ones.
Write down the steps to create a new Database using LibreOffice Base.
Step 1. Click Start > LibreOffice or double click on the LibreOffice icon on the desktop
or Select Base Database option from the bottom left panel.
Step 2. A Database Wizard opens.
Step 3. Click Create a new database radio button. Thereafter click Next button.
Step 4. Click and select the radio button with option, ‘No, do not register the database.
Step 5. Click Finish button to complete the database creation process.
Step 6. Browse for the drive and folder where you want to store your database.
Step 7. Type the name (Sports Day) in the File name text box.
Step 8. Click Save button. The database in Base is saved with an extension. odb.
Name & Explain various components of the Base User Interface of LibreOffice Base?
1. Title Bar – The title bar displays the name of a database and an application in
which it is made.
2. Menu Bar – The menu bar appears below the title bar. It consists of seven menu
items – File, Edit, View, Insert, Tools, Window and Help.
3. Standard Toolbar – It is located below the menu bar. It is used to access frequently
used tools.
4. Status Bar – It is located at the bottom of the interface window. It displays
information about the type of view of the object in the database.
5. Database Pane – The database pane is located on the left side of the window.
How to Create Table using Wizard view in LibreOffice Base?
Step1. Click on the Create Table using Wizard View Option.
Step2. Click the Sample tables list box and select any one table.
Step3. Select required fields from Available fields box and shift one by one to Selected
fields box using > button.
Step 4. Set types and formats. Then click on Next button.
Step5. Click on the Finish button to complete the process.
2. A currency data type can only store monetary data that is in dollars.
(a) True (b) False
(c) Neither a nor b (d) Both a and b