Forum und email

ora_error

(PHP 4, PHP 5 <= 5.0.5)

ora_error — 获得 Oracle 错误信息

描述

string ora_error ([ resource $cursor_or_connection ] )

返回一个 XXX-NNNNN 形式的错误信息,XXX 报告错误来源, NNNNN 报告错误号。

Note: 对 connection ids 的支持从 3.0.4 开始。

在 Unix 版的 Oracle 上,你会发现关于某个错误信息的详细内容与下面的显示类似: $ oerr ora 00001 00001, 00000, "unique constraint (%s.%s) violated" // *Cause: An update or insert statement attempted to insert a duplicate key // For Trusted ORACLE configured in DBMS MAC mode, you may see // this message if a duplicate entry exists at a different level. // *Action: Either remove the unique restriction or do not insert the key