I entered the following SQL commands in Oracle but it complained "ORA-00922: missing or invalid option"
CREATE TABLE Student (
StuID NUMBER(15),
StuName VARCHAR2(50),
Phone VARCHAR2(20),
PRIMARY KEY (StuID))
CREATE TABLE Program (
ProCode VARCHAR2(12),
ProTitle VARCHAR2(50),
PRIMARY KEY (ProCode))
WHY???
ORA-00906: missing left parenthesis Cause: A required left parenthesis has been omitted. Certain commands, such as CREATE TABLE, CREATE CLUSTER, and INSERT, require a list of items enclosed in parentheses. Parentheses also are required around subqueries in WHERE clauses and in UPDATE table SET column = (SELECT...)
Is the command, which may be abbreviated SET DEF. OFF. Disables variable substitution. ON. Enables variable substitution, and resets the substitution prefix character back to the default ampersand (&) character.
If you are using the dreaded HTML GUI (inside the browser) of OracleXE then that does not support running more than one statement.
Use SQL Developer, SQL*Plus or any other GUI tool instead.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With