0
CREATE TABLE MURID2 (
  ID INT NOT NULL AUTO_INCREMENT,
  IDMURID VARCHAR2(4) NOT NULL,
  NAMA VARCHAR2(30),
  NO_HP NUMBER,
  ALAMAT VARCHAR2(30),
  IDKELAS VARCHAR2(6),
  CONSTRAINT PK_MURID PRIMARY KEY (ID)
);  

Why do I have the error ORA-00907: missing right parenthesis?

Cœur
  • 37,241
  • 25
  • 195
  • 267
Yan
  • 27
  • 1
  • 1
  • 6

1 Answers1

1

first if this is oracle remove AUTO_INCREMENT. this is not suppoerted in oracle.

if this is mysql, replace VARCHAR2 with varchar and

replace following line

NO_HP NUMBER,

with

NO_HP NUMBER(10),
reza
  • 1,507
  • 2
  • 12
  • 17
  • maybe my oracle remove auto_increment. how to solve this? – Yan Jun 06 '16 at 13:54
  • as far i know oracle does not have auto_increment facility. you have to create a function or trigger to do it. – reza Jun 06 '16 at 13:59
  • check the following link how to do it http://stackoverflow.com/questions/11296361/how-to-create-id-with-auto-increment-on-oracle – reza Jun 06 '16 at 14:01