Re: [SOLVED] Re: DB uniqueness constraints and dealing with them
Re: [SOLVED] Re: DB uniqueness constraints and dealing with them
- Subject: Re: [SOLVED] Re: DB uniqueness constraints and dealing with them
- From: Neil MacLennan <email@hidden>
- Date: Fri, 04 Jul 2008 22:34:55 +0100
On 4 Jul 2008, at 20:13, Florijan Stamenkovic wrote:
However, the code below does not extrapolate the column name from
the exception, do you maybe have some code for that?
Sadly I don't :-(
The MySQL error (1062) returns a message like, "ERROR 1062 (23000):
Duplicate entry 'AB1' for key 3" where "key 3" is the row number of
MySQL's internal key records table. This table is not indexed so you
must *count* returned rows until you come to the third one and then
query the row to get the column name that owns the unique key. Ugh.
Unless anyone knows different...
.neilmac
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden