Views - Views . own..Itis Advantagesofviews

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
Views A view is a logical table based on a table or another view. The view contains no data of its  own. It’s like a “window” through which data from tables can be viewed or changed. It is  stored in a data dictionary. Advantages of views - Restrict database access because the view can display a selected portion of a database. - Simplify queries to retrieve the results from complicated queries. Hence, users can query  the data from multiple tables without the need to know how to write join statement. - Views provide data independence for application programs because one view can be  used to retrieve data from several tables. Guidelines - The sub-query can contain complex SELECT syntax, including joins, groups and sub- queries. - The query that defines the view cannot contain the ORDER BY clause. - You can use the OR REPLACE option to change the definition of the view without  dropping and recreating the view which would require regranting the privileges.  Exercises Use EMPLOYEES and DEPARTMENTS tables created in the earlier exercises.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
1. Create a view containing the data for all departments. Select all data from the view.
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

Page1 / 9

Views - Views . own..Itis Advantagesofviews

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online