Home Privacy Policy Feedback Link to us Site Map

Oracle/PLSQL: ORA-00928 Error


Error:

ORA-00928: missing SELECT keyword

Cause:

You tried to create a view, but missed the SELECT keyword.

Action:

The options to resolve this Oracle error are:
  1. Correct the CREATE VIEW statement and re-execute it.

For example, if you had tried to create a view as follows:

CREATE VIEW sup_orders AS
supplier.supplier_id, orders.quantity, orders.price
FROM supplier, orders
WHERE supplier.supplier_id = orders.supplier_id
and supplier.supplier_name = 'IBM';


You would receive the following error message:


You could correct the CREATE VIEW statement by including the SELECT keyword as follows:

CREATE VIEW sup_orders AS
SELECT supplier.supplier_id, orders.quantity, orders.price
FROM supplier, orders
WHERE supplier.supplier_id = orders.supplier_id
and supplier.supplier_name = 'IBM';