bugl
bugl
HomeLearnPatternsPathsSearch
HomeLearnPatternsPathsSearch

Loading lesson path

Learn/SQL/SQL References
SQL•SQL References

SQL CREATE OR REPLACE VIEW Keyword

Flash cards

Review the key moves

1/4
Core idea

What is the main idea behind SQL CREATE OR REPLACE VIEW Keyword?

Lesson checks

Practice each idea before moving on

Short Mimo-style checks built from this lesson's code, terms, and sequence.

1Quick choice

Which statement best captures the main point of this lesson?

2Fill blank

Complete the missing token from the example code.

___ OR REPLACE VIEW [Brazil Customers] AS
3Order

Put the learning moves in the order that makes the concept easiest to apply.

The following SQL adds the "City" column to the "Brazil Customers" view:
In MySQL and Oracle, a view can be updated with the CREATE OR REPLACE VIEW command.
Create Or Replace View

Create Or Replace View

In MySQL and Oracle, a view can be updated with the CREATE OR REPLACE VIEW command.

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];

Previous

SQL CREATE INDEX Keyword

Next

SQL CREATE TABLE Keyword