SlideShare a Scribd company logo
8/10/13 SQL Views
beginner-sql-tutorial.com/sql-views.htm 1/1
SQL Views
A VIEW is a virtual table, through which a selective portion of the data from one or more tables can be seen.
Views do not contain data of their own. They are used to restrict access to the database or to hide data
complexity. A view is stored as a SELECT statement in the database. DML operations on a view like INSERT,
UPDATE, DELETE affects the data in the original table upon which the view is based.
The Syntax to create a sql view is
CREATE VIEW view_name
AS
SELECT column_list
FROM table_name [WHERE condition];
view_name is the name of the VIEW.
The SELECT statement is used to define the columns and rows that you want to display in the view.
For Example: to create a view on the product table the sql query would be like
CREATE VIEW view_product
AS
SELECT product_id, product_name
FROM product;

More Related Content

Similar to Sql views (20)

PPTX
View
Pooja Dixit
Ā 
PDF
Sql viwes
Huda Alameen
Ā 
PPTX
Designing and Creating Views, Inline Functions, and Synonyms
Tayba Farooqui
Ā 
PPTX
Lec 09 SQL - 3.pptx
HasankaNayanjith
Ā 
PPT
Oracle view
Madhavendra Dutt
Ā 
PPTX
MS SQL SERVER: Creating Views
sqlserver content
Ā 
PPTX
MS SQLSERVER:Creating Views
sqlserver content
Ā 
PPT
MySQL Views
Reggie Niccolo Santos
Ā 
PPTX
Sql server ___________session_16(views)
Ehtisham Ali
Ā 
PPTX
Creating database using sql commands
Belle Wx
Ā 
DOCX
View
Brijesh Chaudhary
Ā 
PPT
Review of SQL
Information Technology
Ā 
PPTX
Concept of View in Database management system
anjanasharma77573
Ā 
PDF
Sql ch 13 - sql-views
Mukesh Tekwani
Ā 
PPT
Les11
Vijay Kumar
Ā 
PPTX
SQLviews in the Database Management Systems
sudeepraj620
Ā 
PPTX
View
Ramraj Choudhary
Ā 
PDF
oracle database Views_squence_Part_II.pdf
mahmoudnaser14
Ā 
PPT
chap 7.ppt(sql).ppt
arjun431527
Ā 
PPT
Chap 7
Karan Patil
Ā 
View
Pooja Dixit
Ā 
Sql viwes
Huda Alameen
Ā 
Designing and Creating Views, Inline Functions, and Synonyms
Tayba Farooqui
Ā 
Lec 09 SQL - 3.pptx
HasankaNayanjith
Ā 
Oracle view
Madhavendra Dutt
Ā 
MS SQL SERVER: Creating Views
sqlserver content
Ā 
MS SQLSERVER:Creating Views
sqlserver content
Ā 
MySQL Views
Reggie Niccolo Santos
Ā 
Sql server ___________session_16(views)
Ehtisham Ali
Ā 
Creating database using sql commands
Belle Wx
Ā 
Review of SQL
Information Technology
Ā 
Concept of View in Database management system
anjanasharma77573
Ā 
Sql ch 13 - sql-views
Mukesh Tekwani
Ā 
Les11
Vijay Kumar
Ā 
SQLviews in the Database Management Systems
sudeepraj620
Ā 
oracle database Views_squence_Part_II.pdf
mahmoudnaser14
Ā 
chap 7.ppt(sql).ppt
arjun431527
Ā 
Chap 7
Karan Patil
Ā 

More from Vivek Singh (20)

PPS
C programming session 14
Vivek Singh
Ā 
PPS
C programming session 13
Vivek Singh
Ā 
PPS
C programming session 11
Vivek Singh
Ā 
PPS
C programming session 10
Vivek Singh
Ā 
PPS
C programming session 08
Vivek Singh
Ā 
PPS
C programming session 07
Vivek Singh
Ā 
PPS
C programming session 05
Vivek Singh
Ā 
PPS
C programming session 04
Vivek Singh
Ā 
PPS
C programming session 02
Vivek Singh
Ā 
PPS
C programming session 01
Vivek Singh
Ā 
PPS
C programming session 16
Vivek Singh
Ā 
PDF
Niit aptitude question paper
Vivek Singh
Ā 
PDF
Excel shortcut and tips
Vivek Singh
Ā 
PDF
Sql where clause
Vivek Singh
Ā 
PDF
Sql update statement
Vivek Singh
Ā 
PDF
Sql tutorial, tutorials sql
Vivek Singh
Ā 
PDF
Sql subquery
Vivek Singh
Ā 
PDF
Sql select statement
Vivek Singh
Ā 
PDF
Sql rename
Vivek Singh
Ā 
PDF
Sql query tuning or query optimization
Vivek Singh
Ā 
C programming session 14
Vivek Singh
Ā 
C programming session 13
Vivek Singh
Ā 
C programming session 11
Vivek Singh
Ā 
C programming session 10
Vivek Singh
Ā 
C programming session 08
Vivek Singh
Ā 
C programming session 07
Vivek Singh
Ā 
C programming session 05
Vivek Singh
Ā 
C programming session 04
Vivek Singh
Ā 
C programming session 02
Vivek Singh
Ā 
C programming session 01
Vivek Singh
Ā 
C programming session 16
Vivek Singh
Ā 
Niit aptitude question paper
Vivek Singh
Ā 
Excel shortcut and tips
Vivek Singh
Ā 
Sql where clause
Vivek Singh
Ā 
Sql update statement
Vivek Singh
Ā 
Sql tutorial, tutorials sql
Vivek Singh
Ā 
Sql subquery
Vivek Singh
Ā 
Sql select statement
Vivek Singh
Ā 
Sql rename
Vivek Singh
Ā 
Sql query tuning or query optimization
Vivek Singh
Ā 
Ad

Recently uploaded (20)

PDF
Federal dollars withheld by district, charter, grant recipient
Mebane Rash
Ā 
PPTX
Modern analytical techniques used to characterize organic compounds. Birbhum ...
AyanHossain
Ā 
PDF
Right to Information.pdf by Sapna Maurya XI D
Directorate of Education Delhi
Ā 
PDF
Module 1: Determinants of Health [Tutorial Slides]
JonathanHallett4
Ā 
PPTX
Presentation: Climate Citizenship Digital Education
Karl Donert
Ā 
PPTX
Gall bladder, Small intestine and Large intestine.pptx
rekhapositivity
Ā 
PPT
digestive system for Pharm d I year HAP
rekhapositivity
Ā 
PDF
Ziehl-Neelsen Stain: Principle, Procedu.
PRASHANT YADAV
Ā 
PPTX
ABDOMINAL WALL DEFECTS:GASTROSCHISIS, OMPHALOCELE.pptx
PRADEEP ABOTHU
Ā 
PDF
IMP NAAC REFORMS 2024 - 10 Attributes.pdf
BHARTIWADEKAR
Ā 
PDF
BƀI Tįŗ¬P Bį»” TRỢ THEO LESSON TIįŗ¾NG ANH - I-LEARN SMART WORLD 7 - Cįŗ¢ NĂM - CƓ ĐƁ...
Nguyen Thanh Tu Collection
Ā 
PPTX
THE HUMAN INTEGUMENTARY SYSTEM#MLT#BCRAPC.pptx
Subham Panja
Ā 
PPTX
How to Define Translation to Custom Module And Add a new language in Odoo 18
Celine George
Ā 
PPTX
Optimizing Cancer Screening With MCED Technologies: From Science to Practical...
i3 Health
Ā 
PDF
water conservation .pdf by Nandni Kumari XI C
Directorate of Education Delhi
Ā 
PPTX
Mrs Mhondiwa Introduction to Algebra class
sabinaschimanga
Ā 
PDF
Exploring-the-Investigative-World-of-Science.pdf/8th class curiosity/1st chap...
Sandeep Swamy
Ā 
PPTX
Views on Education of Indian Thinkers J.Krishnamurthy..pptx
ShrutiMahanta1
Ā 
PPTX
Accounting Skills Paper-I, Preparation of Vouchers
Dr. Sushil Bansode
Ā 
PDF
Tips for Writing the Research Title with Examples
Thelma Villaflores
Ā 
Federal dollars withheld by district, charter, grant recipient
Mebane Rash
Ā 
Modern analytical techniques used to characterize organic compounds. Birbhum ...
AyanHossain
Ā 
Right to Information.pdf by Sapna Maurya XI D
Directorate of Education Delhi
Ā 
Module 1: Determinants of Health [Tutorial Slides]
JonathanHallett4
Ā 
Presentation: Climate Citizenship Digital Education
Karl Donert
Ā 
Gall bladder, Small intestine and Large intestine.pptx
rekhapositivity
Ā 
digestive system for Pharm d I year HAP
rekhapositivity
Ā 
Ziehl-Neelsen Stain: Principle, Procedu.
PRASHANT YADAV
Ā 
ABDOMINAL WALL DEFECTS:GASTROSCHISIS, OMPHALOCELE.pptx
PRADEEP ABOTHU
Ā 
IMP NAAC REFORMS 2024 - 10 Attributes.pdf
BHARTIWADEKAR
Ā 
BƀI Tįŗ¬P Bį»” TRỢ THEO LESSON TIįŗ¾NG ANH - I-LEARN SMART WORLD 7 - Cįŗ¢ NĂM - CƓ ĐƁ...
Nguyen Thanh Tu Collection
Ā 
THE HUMAN INTEGUMENTARY SYSTEM#MLT#BCRAPC.pptx
Subham Panja
Ā 
How to Define Translation to Custom Module And Add a new language in Odoo 18
Celine George
Ā 
Optimizing Cancer Screening With MCED Technologies: From Science to Practical...
i3 Health
Ā 
water conservation .pdf by Nandni Kumari XI C
Directorate of Education Delhi
Ā 
Mrs Mhondiwa Introduction to Algebra class
sabinaschimanga
Ā 
Exploring-the-Investigative-World-of-Science.pdf/8th class curiosity/1st chap...
Sandeep Swamy
Ā 
Views on Education of Indian Thinkers J.Krishnamurthy..pptx
ShrutiMahanta1
Ā 
Accounting Skills Paper-I, Preparation of Vouchers
Dr. Sushil Bansode
Ā 
Tips for Writing the Research Title with Examples
Thelma Villaflores
Ā 
Ad

Sql views

  • 1. 8/10/13 SQL Views beginner-sql-tutorial.com/sql-views.htm 1/1 SQL Views A VIEW is a virtual table, through which a selective portion of the data from one or more tables can be seen. Views do not contain data of their own. They are used to restrict access to the database or to hide data complexity. A view is stored as a SELECT statement in the database. DML operations on a view like INSERT, UPDATE, DELETE affects the data in the original table upon which the view is based. The Syntax to create a sql view is CREATE VIEW view_name AS SELECT column_list FROM table_name [WHERE condition]; view_name is the name of the VIEW. The SELECT statement is used to define the columns and rows that you want to display in the view. For Example: to create a view on the product table the sql query would be like CREATE VIEW view_product AS SELECT product_id, product_name FROM product;