MySQL Forums
Forum List  »  Newbie

Re: mysql_query returns 1 but mysql_errno is 0
Posted by: Rick James
Date: September 12, 2014 10:42AM

> I meant that in other sessions mysql_errno() returns the expected value for the duplicates, MYSQL_DUPLICATE_KEY_ERROR_CODE.

Yeah, that is what happens when you insert the same value in the same UNIQUE (or PRIMARY) KEY from two threads. Or the same thread.

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.