Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: oracle create index

Re: oracle create index

From: Anna C. Dent <anacedent_at_hotmail.com>
Date: Mon, 21 Jul 2003 16:55:07 -0700
Message-ID: <r3%Sa.16517$Ne.3938@fed1read03>


John wrote:

> I'm new to Oracle, there may be an obvious answer to my problem, but I cant
> seem to figure it out. I'm importing over a mysql database to oracle. A
> number of my tables have indexes that have the same name.
>
> Example of what I am trying to do:
>
> create table mytable1 ( myid NUMBER(10),otherid NUMBER(10));
> create table mytable2 (someid NUMBER(10),otherid NUMBER(10));
>
> create INDEX otherid ON mytable1 (otherid);
> create INDEX otherid ON mytable2 (otherid);
>
> error: ORA-00955: name is already used by an existing object
>
> Can anyone suggest a way to accomplish this?

NO!
You can't use the same name on two different objects of the same type in the same schema.

create INDEX otherid1 ON mytable1 (otherid); create INDEX otherid2 ON mytable1 (otherid); Received on Mon Jul 21 2003 - 18:55:07 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US