English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

SQL CREATE VIEW Keyword Usage and Example

SQL Keyword Reference

CREATE VIEW (Create View)

The CREATE VIEW command creates a view.

A view is a virtual table based on the result set of an SQL statement.

The following SQL creates a view selecting all customers from Brazil:

CREATE VIEW [Brazil 
  Customers] AS
SELECT 
  CustomerName, ContactName
FROM Customers
WHERE 
  Country = "Brazil";

Query View

We can query the following views:

SELECT * FROM [Brazil 
  Customers];

SQL Keyword Reference