oracle - SQL Developer "missing left parenthesis" -


can please me? trying make table coursework have problem foreign keys , don't know why...

i error, when try , create table: "missing left parenthesis"

create table avatar  ( avatar_id number(3) constraint pk_avatar primary key, avatarname varchar(255), dob number(12), gender varchar(1), strength number(12), weapon varchar(255), species varchar(255), cost numbr(20), player_id number(3), foreign key references player(player_id), motheravatar_id number(3), foreign key references motheravatar(motheravatar_id), fatheravatar_id number(3), foreign key references fatheravatar(fatheravatar_id) ); 

try this

create table avatar  ( avatar_id number(3) constraint pk_avatar primary key, avatarname varchar(255), dob number(12), gender varchar(1), strength number(12), weapon varchar(255), species varchar(255), cost number(20), player_id number(3), constraint fk_playerid foreign key (player_id) references player(player_id), motheravatar_id number(3), constraint fk_motheravatar_id foreign key (motheravatar_id) references motheravatar(motheravatar_id), fatheravatar_id number(3),constraint fk_fatheravatar_id foreign key (fatheravatar_id) references fatheravatar(fatheravatar_id) ); 

Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -