0 - Unit 7 DataBase Development
0 - Unit 7 DataBase Development
1
Information Technology Class X
2
Information Technology Class X
A database report is the formatted result of data coming from database objects
like tables or queries. Reports are very useful tools for decision-making and
analysis.
11. Explain the steps in Designing a Database.
Determine the purpose of your database.
Determine the tables you need.
Determine the fields you need.
Identify the field or fields with unique values in each record
Determine the relationships between the tables
Refine your design
Enter data and create other database objects
12. What are the difference between a flat database and relational database?
In a flatfile database, all the data is stored in a single file. It can be used for
small amount of data. e.g. a spreadsheet.
In a relational database, data is stored in multiple tables linked via common
fields. It can be used for large amount of data. e.g. Microsoft SQL.
13. Define RDBMS.
RDBMS stands for Relational Database Management System. It is a type of
DBMS software which uses relational model for its database. In this model all the
data is stored in a structured tabular format consisting of rows and columns. It also
provides a facility, to define a primary key for unique identification of each table.
14. Define database servers.
A database server refers to a server which offers dataset services to other
computers or computer programs as defines by the client-server model. Database
servers are dedicated computer that hold the actual databases and run only the
DBMS and related software. Users access a database server either through a “front
end”, which displays the requested data or through “back end” which runs on the
server and handles tasks such as data analysis and storage. Such type of data access
is referred to as a client-server model.
3
Information Technology Class X
Statement Description
CREATE Creates new database / table
ALTER Modifies the structure of database/table
DROP Deletes a database/table
TRUNCATE Removes all table records including allocated table spaces
RENAME Renames the database/table
19. Define DML.
DML stands for Data Manipulation Language. As this name suggests this
language includes commands that allow users to manipulate data in a database.
These commands help in retrieval, insertion, deletion and modification of the
information present in the database. Commands which fall under this category are:
Statement Description
SELECT Retrieves data from the table
INSERT Inserts data into a table
UPDATE Updates the existing data with new data within a table
DELETE Deletes the records rows from the table.
4
Information Technology Class X
e.g.
Insert into SDetails (“ID”, “Name”, “Rollno”, “DOB”, “Class”, “Phone”,
“Email”, “Color”, “Location”) values (‘8’, ‘Ranjith Singh’, ’67’, ‘12-03-99’,’X’,
‘435363’, ‘[email protected]’, ‘White’, ‘Bihar’);
25. Explain about UPDATE statement in Database.
Update statement is used for modifying records in a database. The general
syntax of the update statement is as follows:
UPDATE <table_name> SET <column_name> = value [, column_name =
value ...] [WHERE <condition>];
e.g. Update SDetails set Location = ‘Bhubaneswar’ where Rollno = 14;
26. Explain about DELETE statement in Database.
Delete Statement is used to remove one or more records in a database. The
general syntax of the
delete statement is as follows:
DELETE FROM <table_name> [WHERE] <condition>;
To delete one of the records in the table created earlier using delete statement, type
the following
and click Execute:
delete from SDetails where ID=8;
27. Explain about CREATE statement in Database.
Create statement is used for creating a database or a table in any RDBMS
Software. A commonly used CREATE command is the CREATE TABLE
command. The general syntax of the create statement is shown below.
CREATE TABLE <TABLENAME> ([column definitions]) [table parameters]
Column definitions: A comma-separated list consisting of any of the following
Column definition: [column name] [data type] {NULL | NOT NULL} {column
options}
Primary key definition: PRIMARY KEY ([comma separated column list])
For example, if you would like to create a table using the Create statement, type the
following and click Execute.
CREATE TABLE Employee (ID INTEGER, Name VARCHAR (50), Department
VARCHAR (50), Address VARCHAR (120), Contact_Number INTEGER);
*****************
6