Oracle Create View Syntax & Example
To create a view in Oracle, you can use the following SQL statement:
CREATE VIEW view_name AS
SELECT column1, column2, ...
FROM table_name
WHERE condition;
The view_name is the name of the view to be created, column1, column2, … are the names of the columns included in the view, table_name is the name of the table on which the view is based, and the condition is an optional filtering condition.
For instance, to create a view named employee_view that includes employee names and salary information from the employees table, you can use the following SQL statement:
CREATE VIEW employee_view AS
SELECT employee_name, salary
FROM employees;