mirror of
https://github.com/php/doc-zh.git
synced 2026-03-24 07:02:15 +01:00
915 lines
28 KiB
XML
Executable File
915 lines
28 KiB
XML
Executable File
<?xml version="1.0" encoding="utf-8"?>
|
||
<!-- $Revision$ -->
|
||
<!-- EN-Revision: 3c6c95fcfd7d9eaa603df40327693ea8dff89d53 Maintainer: dallas Status: ready -->
|
||
<!-- CREDITS: mowangjuanzi, Luffy -->
|
||
<appendix xml:id="pgsql.constants" xmlns="http://docbook.org/ns/docbook">
|
||
&reftitle.constants;
|
||
&extension.constants;
|
||
|
||
<variablelist>
|
||
<varlistentry xml:id="constant.pgsql-libpq-version">
|
||
<term>
|
||
<constant>PGSQL_LIBPQ_VERSION</constant>
|
||
(<type>string</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
仅包含数字和小数点的简短 libpq 版本号。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-libpq-version-str">
|
||
<term>
|
||
<constant>PGSQL_LIBPQ_VERSION_STR</constant>
|
||
(<type>string</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
PHP 8.0.0 之前为包含编译信息的长 libpq 版本号。自 PHP 8.0.0 起,此值与 <constant>PGSQL_LIBPQ_VERSION</constant>
|
||
相同,并且弃用 <constant>PGSQL_LIBPQ_VERSION_STR</constant>。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-assoc">
|
||
<term>
|
||
<constant>PGSQL_ASSOC</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_fetch_array</function>。返回字段名和值的关联数组。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-num">
|
||
<term>
|
||
<constant>PGSQL_NUM</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_fetch_array</function>。返回字段编号和值的数字索引数组。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-both">
|
||
<term>
|
||
<constant>PGSQL_BOTH</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_fetch_array</function>。返回字段值数组,这些字段值既有数字索引(按字段编号)也有关联索引(按字段名称)。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connect-force-new">
|
||
<term>
|
||
<constant>PGSQL_CONNECT_FORCE_NEW</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_connect</function> 以强制创建新连接,而不是重新使用现有的相同连接。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connect-async">
|
||
<term>
|
||
<constant>PGSQL_CONNECT_ASYNC</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_connect</function> 以创建异步连接。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-auth-ok">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_AUTH_OK</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-awaiting-response">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_AWAITING_RESPONSE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-bad">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_BAD</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connection_status</function> 返回,表示数据库连接处于无效状态。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-made">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_MADE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-ok">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_OK</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connection_status</function> 返回,表示数据库连接处于有效状态。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-setenv">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_SETENV</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-ssl-startup">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_SSL_STARTUP</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-connection-started">
|
||
<term>
|
||
<constant>PGSQL_CONNECTION_STARTED</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-seek-set">
|
||
<term>
|
||
<constant>PGSQL_SEEK_SET</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_lo_seek</function>。寻找操作是从对象的开头开始的。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-seek-cur">
|
||
<term>
|
||
<constant>PGSQL_SEEK_CUR</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_lo_seek</function>。寻找操作是从当前位置开始的。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-seek-end">
|
||
<term>
|
||
<constant>PGSQL_SEEK_END</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_lo_seek</function>。寻找操作是从对象的末尾开始。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-empty-query">
|
||
<term>
|
||
<constant>PGSQL_EMPTY_QUERY</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。发送到服务器的字符串为空。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-command-ok">
|
||
<term>
|
||
<constant>PGSQL_COMMAND_OK</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。成功完成命令不返回任何数据。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-tuples-ok">
|
||
<term>
|
||
<constant>PGSQL_TUPLES_OK</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。成功完成一个返回数据的命令(例如 <literal>SELECT</literal> 或 <literal>SHOW</literal>)。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-tuples-chunk">
|
||
<term>
|
||
<constant>PGSQL_TUPLES_CHUNK</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。表示命令执行完毕,以分块模式返回数据。当设置了
|
||
<function>pg_set_chunked_rows_size</function> 时,将返回 <literal>SELECT</literal>
|
||
命令。结果集分为多个块,每个块包含预定义的行数。自 PHP 8.4.0 和 libpq 17 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-copy-out">
|
||
<term>
|
||
<constant>PGSQL_COPY_OUT</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。开始复制(从服务器)数据传输。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-copy-in">
|
||
<term>
|
||
<constant>PGSQL_COPY_IN</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。开始复制(到服务器)数据传输。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-bad-response">
|
||
<term>
|
||
<constant>PGSQL_BAD_RESPONSE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。无法理解服务器的响应。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-nonfatal-error">
|
||
<term>
|
||
<constant>PGSQL_NONFATAL_ERROR</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。发生非致命错误(通知或警告)。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-fatal-error">
|
||
<term>
|
||
<constant>PGSQL_FATAL_ERROR</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_result_status</function> 返回。发生致命错误。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-transaction-idle">
|
||
<term>
|
||
<constant>PGSQL_TRANSACTION_IDLE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_transaction_status</function> 返回。当前连接处于空闲状态,不在事务中。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-transaction-active">
|
||
<term>
|
||
<constant>PGSQL_TRANSACTION_ACTIVE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_transaction_status</function> 返回。连接正在执行命令。查询(query)已通过连接发送但尚未完成。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-transaction-intrans">
|
||
<term>
|
||
<constant>PGSQL_TRANSACTION_INTRANS</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_transaction_status</function> 返回。连接处于空闲状态且处于事务块中。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-transaction-inerror">
|
||
<term>
|
||
<constant>PGSQL_TRANSACTION_INERROR</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_transaction_status</function> 返回。连接处于空闲状态且处于失败的事务块中。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-transaction-unknown">
|
||
<term>
|
||
<constant>PGSQL_TRANSACTION_UNKNOWN</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_transaction_status</function> 返回。连接损坏。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-severity">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SEVERITY</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。严重程度;字段内容是
|
||
<literal>ERROR</literal>、<literal>FATAL</literal> 或 <literal>PANIC</literal>(在 error 消息中)或
|
||
<literal>WARNING</literal>、<literal>NOTICE</literal>、<literal>DEBUG</literal>、<literal>INFO</literal>
|
||
或 <literal>LOG</literal>(在 notice 消息中),或其中之一的本地化翻译。始终存在。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-sqlstate">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SQLSTATE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。error 的 SQLSTATE 代码。SQLSTATE
|
||
代码标识已发生的错误类型;前端应用程序可以使用它来执行特定操作(例如错误处理)以响应特定的数据库错误。该字段不可本地化,并且始终存在。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-message-primary">
|
||
<term>
|
||
<constant>PGSQL_DIAG_MESSAGE_PRIMARY</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
人可读的主要错误消息(通常是一行)。始终存在。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-message-detail">
|
||
<term>
|
||
<constant>PGSQL_DIAG_MESSAGE_DETAIL</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
详细信息:可选的次要错误消息,其中包含有关该问题的更多详细信息。可能会有多行。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-message-hint">
|
||
<term>
|
||
<constant>PGSQL_DIAG_MESSAGE_HINT</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
提示:关于如何处理该问题的可选建议。这与细节不同,因为它提供建议(可能不合适)而不是确凿的事实。可能会有多行。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-statement-position">
|
||
<term>
|
||
<constant>PGSQL_DIAG_STATEMENT_POSITION</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
包含十进制整数的字符串,指示错误游标位置作为原始语句字符串的索引。第一个字符的索引为 1,位置以字符而不是字节为单位进行测量。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-internal-position">
|
||
<term>
|
||
<constant>PGSQL_DIAG_INTERNAL_POSITION</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。该字段的定义与 <constant>PG_DIAG_STATEMENT_POSITION</constant>
|
||
字段相同,但当光标位置引用内部生成的命令(而不是客户端提交的命令)时,会使用该常量。
|
||
当此字段出现时,<constant>PG_DIAG_INTERNAL_QUERY</constant> 字段将始终出现。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-internal-query">
|
||
<term>
|
||
<constant>PGSQL_DIAG_INTERNAL_QUERY</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
失败的内部生成命令的文本。例如,这可能是由 PL/pgSQL 函数发出的 SQL 查询。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-context">
|
||
<term>
|
||
<constant>PGSQL_DIAG_CONTEXT</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
错误发生时的上下文指示。目前包括活动过程语言函数和内部生成的查询调用堆栈回溯。跟踪是每行一个条目,最近的条目在前。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-source-file">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SOURCE_FILE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
报告错误的 PostgreSQL 源代码位置的文件名。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-source-line">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SOURCE_LINE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
报告错误的 PostgreSQL 源代码位置的行号。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-source-function">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SOURCE_FUNCTION</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_error_field</function>。
|
||
报告错误的 PostgreSQL 源代码函数的名称。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-schema-name">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SCHEMA_NAME</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
自 PHP 7.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-table-name">
|
||
<term>
|
||
<constant>PGSQL_DIAG_TABLE_NAME</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
自 PHP 7.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-column-name">
|
||
<term>
|
||
<constant>PGSQL_DIAG_COLUMN_NAME</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
自 PHP 7.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-datatype-name">
|
||
<term>
|
||
<constant>PGSQL_DIAG_DATATYPE_NAME</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
自 PHP 7.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-constraint-name">
|
||
<term>
|
||
<constant>PGSQL_DIAG_CONSTRAINT_NAME</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
自 PHP 7.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
|
||
<varlistentry xml:id="constant.pgsql-errors-terse">
|
||
<term>
|
||
<constant>PGSQL_ERRORS_TERSE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_set_error_verbosity</function>。指定返回的消息,仅包括严重性、主要文本和位置;通常适合单行。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-errors-default">
|
||
<term>
|
||
<constant>PGSQL_ERRORS_DEFAULT</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_set_error_verbosity</function>。默认模式生成的消息包括上述内容以及所有的详细信息、提示或上下文字段(这些可能会有多行)。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-errors-verbose">
|
||
<term>
|
||
<constant>PGSQL_ERRORS_VERBOSE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_set_error_verbosity</function>。详细模式包括所有可用字段。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-errors-sqlstate">
|
||
<term>
|
||
<constant>PGSQL_ERRORS_SQLSTATE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_set_error_verbosity</function>。仅包括错误严重性和 <literal>SQLSTATE</literal>
|
||
错误代码。如果没有可用的错误代码,则输出类似于 <constant>PGSQL_ERRORS_TERSE</constant> 模式。在 PostgreSQL 11.1
|
||
之前,输出始终与 <constant>PGSQL_ERRORS_TERSE</constant> 模式相同。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
|
||
<varlistentry xml:id="constant.pgsql-notice-last">
|
||
<term>
|
||
<constant>PGSQL_NOTICE_LAST</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
用于 <function>pg_last_notice</function>。自 PHP 7.1.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-notice-all">
|
||
<term>
|
||
<constant>PGSQL_NOTICE_ALL</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
用于 <function>pg_last_notice</function>。自 PHP 7.1.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-notice-clear">
|
||
<term>
|
||
<constant>PGSQL_NOTICE_CLEAR</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
用于 <function>pg_last_notice</function>。自 PHP 7.1.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
|
||
<varlistentry xml:id="constant.pgsql-status-long">
|
||
<term>
|
||
<constant>PGSQL_STATUS_LONG</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_status</function>。表示需要的数字结果代码。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-status-string">
|
||
<term>
|
||
<constant>PGSQL_STATUS_STRING</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_result_status</function>。表示需要的文本结果命令标记。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
|
||
<varlistentry xml:id="constant.pgsql-conv-ignore-default">
|
||
<term>
|
||
<constant>PGSQL_CONV_IGNORE_DEFAULT</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_convert</function>。转换期间忽略表中的默认值。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-conv-force-null">
|
||
<term>
|
||
<constant>PGSQL_CONV_FORCE_NULL</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_convert</function>。使用 SQL <literal>NULL</literal> 代替空 <type>string</type>。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-conv-ignore-not-null">
|
||
<term>
|
||
<constant>PGSQL_CONV_IGNORE_NOT_NULL</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_convert</function>。不会将 &null; 转换为 SQL <literal>NOT NULL</literal> 列。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
|
||
<varlistentry xml:id="constant.pgsql-dml-no-conv">
|
||
<term>
|
||
<constant>PGSQL_DML_NO_CONV</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_insert</function>、<function>pg_select</function>、<function>pg_update</function> 和
|
||
<function>pg_delete</function>。所有参数按原样传递。如果参数包含用户提供的数据,则需要使用 <function>pg_escape_string</function> 手动转义。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-dml-exec">
|
||
<term>
|
||
<constant>PGSQL_DML_EXEC</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_insert</function>、<function>pg_select</function>、<function>pg_update</function> 和
|
||
<function>pg_delete</function>。通过这些函数执行查询。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-dml-async">
|
||
<term>
|
||
<constant>PGSQL_DML_ASYNC</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_insert</function>、<function>pg_select</function>、<function>pg_update</function> 和
|
||
<function>pg_delete</function>。通过这些函数执行异步查询。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-dml-string">
|
||
<term>
|
||
<constant>PGSQL_DML_STRING</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_insert</function>、<function>pg_select</function>、<function>pg_update</function> 和
|
||
<function>pg_delete</function>。返回执行的查询字符串。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-dml-escape">
|
||
<term>
|
||
<constant>PGSQL_DML_ESCAPE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
传递给 <function>pg_insert</function>、<function>pg_select</function>、<function>pg_update</function> 和
|
||
<function>pg_delete</function>。将转义应用于所有参数,而不是在内部调用
|
||
<function>pg_convert</function>。此选项省略元数据查找。查询可能与 <function>pg_query</function>
|
||
和 <function>pg_send_query</function> 一样快。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-polling-failed">
|
||
<term>
|
||
<constant>PGSQL_POLLING_FAILED</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connect_poll</function> 返回,表示尝试连接失败。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-polling-reading">
|
||
<term>
|
||
<constant>PGSQL_POLLING_READING</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connect_poll</function> 返回,表示该连接正在等待 PostgreSQL 套接字可读。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-polling-writing">
|
||
<term>
|
||
<constant>PGSQL_POLLING_WRITING</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connect_poll</function> 返回,表示该连接正在等待 PostgreSQL 套接字可写。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-polling-ok">
|
||
<term>
|
||
<constant>PGSQL_POLLING_OK</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connect_poll</function> 返回,表示连接已准备就绪,可以使用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-polling-active">
|
||
<term>
|
||
<constant>PGSQL_POLLING_ACTIVE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
由 <function>pg_connect_poll</function> 返回,表示该连接当前处于活动状态。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-diag-severity-nonlocalized">
|
||
<term>
|
||
<constant>PGSQL_DIAG_SEVERITY_NONLOCALIZED</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
严重程度;字段内容是 ERROR、FATAL 或 PANIC(在错误消息中)或 WARNING、NOTICE、DEBUG、INFO 或 LOG(在通知消息中)。这与
|
||
PG_DIAG_SEVERITY 字段相同,只是内容从未本地化。这仅存在于 9.6 及更高版本/PHP 7.3.0 及更高版本中。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-show-context-never">
|
||
<term>
|
||
<constant>PGSQL_SHOW_CONTEXT_NEVER</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
跟 <function>pg_set_error_context_visibility</function>
|
||
一起使用,上下文永远不会显示。自 PHP 8.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-show-context-errors">
|
||
<term>
|
||
<constant>PGSQL_SHOW_CONTEXT_ERRORS</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
跟 <function>pg_set_error_context_visibility</function>
|
||
一起使用,上下文字段仅包含在错误消息中。这是默认行为。自 PHP 8.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-show-context-always">
|
||
<term>
|
||
<constant>PGSQL_SHOW_CONTEXT_ALWAYS</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
跟 <function>pg_set_error_context_visibility</function>
|
||
一起使用,上下文字段包含在 error、notice 和 warning 消息中。自 PHP 8.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-trace-suppress-timestamps">
|
||
<term>
|
||
<constant>PGSQL_TRACE_SUPPRESS_TIMESTAMPS</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
跟 <function>pg_trace</function> 一起使用,时间戳不包含在跟踪消息中。自 PHP 8.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
<varlistentry xml:id="constant.pgsql-trace-regress-mode">
|
||
<term>
|
||
<constant>PGSQL_TRACE_REGRESS_MODE</constant>
|
||
(<type>int</type>)
|
||
</term>
|
||
<listitem>
|
||
<simpara>
|
||
跟 <function>pg_trace</function> 一起使用,比如 OID 等字段包含在跟踪消息中。自 PHP 8.3.0 起可用。
|
||
</simpara>
|
||
</listitem>
|
||
</varlistentry>
|
||
</variablelist>
|
||
</appendix>
|
||
<!-- Keep this comment at the end of the file
|
||
Local variables:
|
||
mode: sgml
|
||
sgml-omittag:t
|
||
sgml-shorttag:t
|
||
sgml-minimize-attributes:nil
|
||
sgml-always-quote-attributes:t
|
||
sgml-indent-step:1
|
||
sgml-indent-data:t
|
||
indent-tabs-mode:nil
|
||
sgml-parent-document:nil
|
||
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
|
||
sgml-exposed-tags:nil
|
||
sgml-local-catalogs:nil
|
||
sgml-local-ecat-files:nil
|
||
End:
|
||
vim600: syn=xml fen fdm=syntax fdl=2 si
|
||
vim: et tw=78 syn=sgml
|
||
vi: ts=1 sw=1
|
||
-->
|