SQL CREATE OR REPLACE VIEW Keyword


CREATE OR REPLACE VIEW

The CREATE OR REPLACE VIEW command updates a view.

The following SQL adds the "City" column to the "Brazil Customers" view:

Example

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

Query The View

We can query the view above as follows:

Example

SELECT * FROM [Brazil Customers];


Login
ADS CODE