Re: update on a primary key
Posted in 2005
Topics: General Discussion
I'm not aware of that concept. But I'm sure IDS permit it. J. -----Original Message----- From: Anurag Chakravarti <anurag_chakravarti@persistent.co.in> To: informix-list@iiug.org Date: Fri, 17 Jun 2005 19:02:30 +0530 Subject: update on a primary key Hi, I am new to IDS and I noticed the following: IDS allows update on a primary key. Is not this, well, against the DBMS concepts, where a primary key cannot be updated but a unique index can be. Am I missing some primary key constraint here? :-) -Anurag Jean Sagi jeansagi@myrealbox.com jeansagi@gmail.com sending to informix-list
Anurag Chakravarti <anurag_chakravarti@persistent.co.in> wrote: > I am new to IDS and I noticed the following: > > IDS allows update on a primary key. Is not this, well, against the DBMS > concepts, where a primary key cannot be updated but a unique index can > be. There's nothing in the relational model that says that primary keys cannot be updated, though it is usually advisable to avoid doing so, primarily (if you'll excuse the awful pun) to avoid having to update all the rows in related tables that reference the primary key value that is updated. If you are using surrogates, as in RM/T, then you never update those values. > Am I missing some primary key constraint here? IDS does not allow you to update a SERIAL column (or, I assume but have not verified, a SERIAL8 column). -- Jonathan Leffler #include <disclaimer.h> Email: jleffler@earthlink.net, jleffler@us.ibm.com Guardian of DBD::Informix v2005.01 -- http://dbi.perl.org/