What is basic SELECT statement?

Image
SELECT Statement
A SELECT statement retrieves data from the database. With SELECT statement PROJECTION, SELECTION and JOIN can be performed on database tables.
As data in relational database is stored in TABLES. TABLE has ROW and COLUMN structure. With SELECT statement all rows and all columns can be retrieved, this is known as PROJECTION. But, if rows and columns are retrieved on the basis of some condition, it is known as SELECTION. And suppose if some information is needed and that is stored in two or more different tables but are related, use JOINS to retrieve it from two or more tables.
In SQL, basic SELECT statements are as follows:
SELECT * FROM [table_name];
SELECT[column1][column2][column3],..... FROM  [table_name];
SELECT and FROM are known as clauses. 
SELECT clause allows to specify columns to be selected from the database table. 
FROM clause allows to specify table name that has those column to be selected.
Semicolon at the end of SELECT statement specify the end of SQL statemen…

What are the main advantages of DBMS?

Handle Redundancy: Storing same data at multiple locations is known as data  redundancy. Database system provide central storage mechanism. Copies of data are not created. It saves storage space as well as effort of accessing the data. 

Avoid Inconsistency: Redundancy brings inconsistency. Suppose, multiple copies of same data are available at different locations and data is updated only in few locations but not in all locations. This is inconsistency, different values of same data at different locations and it create confusion. Database system's centralized storage avoid this problem.

Data Sharing: Data stored for one application can be used for another application. Database system provides fast and efficient data access over digital network.

Enforcing Standards: Database system has centralized environment and this makes easy for DBA to create and enforce standards between users. 

Data Isolation: Database systems provide centralized data storage in a single format instead of storing data at multiple location in different formats. It makes application development easy and fast.

Integrity: Always maintain the accuracy of stored data in database system is known as data integrity. In order to maintain the integrity for always storing the correct data, some integrity constraints are defined and enforced on the database system. 

Enforcing Security: DBA define user groups and authorization for controlling data access. As database system is centralized and used by multiple users, it is necessary to enforce security to maintain confidentiality in accessing relevant data.

Backup and Recovery: A database system provide techniques for recovering from hardware or software failures.  


Comments

Popular posts from this blog

With the help of block diagram explain the architecture of a DBMS.

What do you mean by data model? What are different types of data models?

What are the different types of database users?