Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 11.0.1 (中文) » SQL Anywhere 服务器 - 编程 » SQL Anywhere 数据访问 API » SQL Anywhere PHP API » SQL Anywhere PHP API 参考

 

sasql_error

原型
string sasql_error( [ sasql_conn $conn ] )
说明

返回最近执行的 SQL Anywhere PHP 函数的错误文本。错误消息按连接进行存储。如果未指定 $conn,则 sasql_error 返回没有可用连接的最后一条错误消息。例如,如果您调用 sasql_connect,但连接失败,则可调用不含 $conn 参数的 sasql_error 以获取错误消息。如果要获取相应的 SQL Anywhere 错误代码值,则使用 sasql_errorcode 函数。

参数

$conn   由连接函数返回的连接资源。

返回值

描述错误的字符串。有关错误消息的列表,请参见SQL Anywhere 错误消息

相关函数