Sie sind auf Seite 1von 2

What is the database?

The database is a computer file that be used to store the data in


structured way, this database file can be managed by software to make it
accessible to application and to manage the data

What are kinds of database?


a flat database : the database without any relations between its tables
and this kind is useless in the big project with bid data
Relational database : that eliminating the repeating in data and Retrieve
this data more efficient

Why we using software like SQL not store the data in text file?
Because of these reasons
1-data integrity
2- over data
3-outdated data
4-retriving, filtering, searching
5-protect data from unauthorized

What is a SQL?
Structure Query Language (SQL) is an application that allows you to
create and manage database

RDBMS
RDBMS stands for Relational Database Management System.
RDBMS is the basis for SQL, and for all modern database systems like MS
SQL Server, IBM DB2, Oracle, MySQL, and Microsoft Access.
this system makes managing data easy by taking care of many of the
most difficult tasks , and save effort and duplicate the data more than
once
the data integrity is the main job of the RDBMS
The data in RDBMS is stored in database objects called tables.
A table is a collections of related data entries and it consists of columns
and rows.

What Can SQL do?


SQL can execute queries against a database
SQL can retrieve data from a database
SQL can insert records in a database
SQL can update records in a database
SQL can delete records from a database
SQL can create new databases
SQL can create new tables in a database
SQL can create stored procedures in a database
SQL can create views in a database
SQL can set permissions on tables, procedures, and views
Types of Transact-SQL Statements
1-Data Definition Language statements (DDL)
2-Data Manipulation Language statements (DML)
3- Data Control Language statements (DCL)

DDL
Define the data object
CREATE object name
To create a new object like new database , new table,…..
ALTER object name
To make any update in an existing object
DROP object name
To delete any existing object like database, table, …….

DML
TO deal with the data inside these object
SELECT
To retrieve existing data and can filter this data in retrieving
INSERT
To insert new data in table
UPDATE
To update information in existing data
DELETE
To delete any data

DCL
SET or change permissions
1-GRANT
Allow user to work with data
2-DENY
Prevent the user from inheriting the permission through its group
3-REVOKE
Remove granted or denied permission

Das könnte Ihnen auch gefallen