Sven Koehler schrieb:

So i drop the primary key
alter table server_gruppen drop primary key

and added ( the old and the new)
alter table server_gruppen add primary key (nr,server)

Maybe, Elke, you about this, i think to add a primary key to an existing primary key should work.
I think it will be nicer to do this in one step instead of two...;-))))

A key connot be altered - only dropped and re-created.
That doesn't apply to primary keys only, but also to unique or normal indexes.

the two statements:
alter table server_gruppen add primary key (nr)
alter table server_gruppen add primary key (server)
have a different meaning than
alter table server_gruppen add primary key (nr,server)

the first two statements create _two_ keys of one column each
the third statement creates _one_ key of _two_ columns

I don't agree with you to include support for "adding a primary key to another". That doesn make any sense.
This did not know, sure this don't make sense.


Are you sure you didn't mean
  create unique index server on table(server)
instead of
  alter table server_gruppen add primary key (server)
??

yes, i needed two primary key


_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general


However, thanks for your help.

Andreas


_______________________________________________
sapdb.general mailing list
[EMAIL PROTECTED]
http://listserv.sap.com/mailman/listinfo/sapdb.general

Reply via email to