Use the CREATE VIEW statement to create a view on existing tables or views. You specify the name for the VIEW.

The following example demonstrates the use of a code sample. The statement is used to retrieve information from the customer base, but only information on those customers located within the six New England states.

 CREATE VIEW ne_customer AS
     SELECT cust_no, last_name, street, city, state
     FROM SPORTS.customer
     WHERE state in ('NH', 'MA', 'ME', 'CT', 'RI', 'VT') ;