2008年12月11日星期四

Re: [fw-db] constriants: delete (NO ACTION)

i check the zend code and it's only returning the number of deleted rows.
So there's no error code comming back...


Graham Anderson wrote:
>
> On Wednesday 10 December 2008 13:57:49 PHPScriptor wrote:
>>but I can't figure out what kind of error the delete is returning now. So
I
>>can show a decend message to my users when they are trying to delete a
>>relation.
>>
>>Someone an idea, maybe there is already somewhere/someone who builded code
>>to do the error followup?
>
> This type of error should always contain the following pattern.
>
> The error code "SQLSTATE[23000]", this is SQL standard error code for an
> integrity constraint violation.
>
> Also possibly the text pattern "integrity constraint violation", while you
> would expect this and in fact PDO does include this text pattern in its
> error
> messages of this type; the SQL standard doesn't provide for the text
> content
> of the error messages, only the sqlstate type error codes.
>
> You should check with your rdbms vendor documentation to be sure.
>
> Graham
>
>
>


-----
visit my website at http://www.phpscriptor.com/ http://www.phpscriptor.com/
--
View this message in context: http://www.nabble.com/constriants%3A-delete-%28NO-ACTION%29-tp20934833p20958593.html
Sent from the Zend DB mailing list archive at Nabble.com.

没有评论: