O'Reilly logo

SQL Server 2014 Development Essentials by Basit A. Masood-Al-Farooq

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating and using views

A view is a virtual table whose result set is derived from a query. In reality, a view is simply a SELECT statement that is saved with the name in the database. Views are used just like regular tables without incurring additional cost, unless you are indexing the view. We typically create views based on one or more tables, views, CTEs, table-valued functions, or a combination of them all. We can reference views in Transact-SQL statements in the same way tables are referenced. We can also perform DML operations on views. The typical uses of views include:

  • A denormalized presentation of normalized data
  • Limiting access to specific columns of the underlying tables
  • Creating a reusable set of data
  • Restricting users' access to sensitive ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required