下列常量由此扩展定义,且仅在此扩展编译入 PHP 或在运行时动态载入时可用。
Most of the constants refer to details of the MySQL Client Server Protocol. Please, refer to the MySQL reference manual to learn about their meaning. To avoid content duplication, only short descriptions are given.
MysqlndUhConnection::simpleCommand() related
The following constants can be used to detect what command is to be send through MysqlndUhConnection::simpleCommand().
MYSQLND_UH_MYSQLND_COM_SLEEP
(int)
MYSQLND_UH_MYSQLND_COM_QUIT
(int)
MYSQLND_UH_MYSQLND_COM_INIT_DB
(int)
MYSQLND_UH_MYSQLND_COM_QUERY
(int)
MYSQLND_UH_MYSQLND_COM_FIELD_LIST
(int)
MYSQLND_UH_MYSQLND_COM_CREATE_DB
(int)
MYSQLND_UH_MYSQLND_COM_DROP_DB
(int)
MYSQLND_UH_MYSQLND_COM_REFRESH
(int)
MYSQLND_UH_MYSQLND_COM_SHUTDOWN
(int)
MYSQLND_UH_MYSQLND_COM_STATISTICS
(int)
MYSQLND_UH_MYSQLND_COM_PROCESS_INFO
(int)
MYSQLND_UH_MYSQLND_COM_CONNECT
(int)
MYSQLND_UH_MYSQLND_COM_PROCESS_KILL
(int)
MYSQLND_UH_MYSQLND_COM_DEBUG
(int)
MYSQLND_UH_MYSQLND_COM_PING
(int)
MYSQLND_UH_MYSQLND_COM_TIME
(int)
MYSQLND_UH_MYSQLND_COM_DELAYED_INSERT
(int)
MYSQLND_UH_MYSQLND_COM_CHANGE_USER
(int)
MYSQLND_UH_MYSQLND_COM_BINLOG_DUMP
(int)
MYSQLND_UH_MYSQLND_COM_TABLE_DUMP
(int)
MYSQLND_UH_MYSQLND_COM_CONNECT_OUT
(int)
MYSQLND_UH_MYSQLND_COM_REGISTER_SLAVED
(int)
MYSQLND_UH_MYSQLND_COM_STMT_PREPARE
(int)
MYSQLND_UH_MYSQLND_COM_STMT_EXECUTE
(int)
MYSQLND_UH_MYSQLND_COM_STMT_SEND_LONG_DATA
(int)
MYSQLND_UH_MYSQLND_COM_STMT_CLOSE
(int)
MYSQLND_UH_MYSQLND_COM_STMT_RESET
(int)
MYSQLND_UH_MYSQLND_COM_SET_OPTION
(int)
MYSQLND_UH_MYSQLND_COM_STMT_FETCH
(int)
MYSQLND_UH_MYSQLND_COM_DAEMON
(int)
MYSQLND_UH_MYSQLND_COM_END
(int)
The following constants can be used to analyze the ok_packet
argument of MysqlndUhConnection::simpleCommand().
MYSQLND_UH_MYSQLND_PROT_GREET_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_AUTH_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_OK_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_EOF_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_CMD_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_RSET_HEADER_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_RSET_FLD_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_ROW_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_STATS_PACKET
(int)
MYSQLND_UH_MYSQLND_PREPARE_RESP_PACKET
(int)
MYSQLND_UH_MYSQLND_CHG_USER_RESP_PACKET
(int)
MYSQLND_UH_MYSQLND_PROT_LAST
(int)
MysqlndUhConnection::close() related
The following constants can be used to detect why a connection has been
closed through MysqlndUhConnection::close()
.
MYSQLND_UH_MYSQLND_CLOSE_EXPLICIT
(int)
MYSQLND_UH_MYSQLND_CLOSE_IMPLICIT
(int)
MYSQLND_UH_MYSQLND_CLOSE_DISCONNECTED
(int)
MYSQLND_UH_MYSQLND_CLOSE_LAST
(int)
MysqlndUhConnection::setServerOption() related
The following constants can be used to detect which option is set through
MysqlndUhConnection::setServerOption()
.
MYSQLND_UH_SERVER_OPTION_MULTI_STATEMENTS_ON
(int)
MYSQLND_UH_SERVER_OPTION_MULTI_STATEMENTS_OFF
(int)
MysqlndUhConnection::setClientOption() related
The following constants can be used to detect which option is set through MysqlndUhConnection::setClientOption().
MYSQLND_UH_MYSQLND_OPTION_OPT_CONNECT_TIMEOUT
(int)
MYSQLND_UH_MYSQLND_OPTION_OPT_COMPRESS
(int)
MYSQLND_UH_MYSQLND_OPTION_OPT_NAMED_PIPE
(int)
MYSQLND_UH_MYSQLND_OPTION_INIT_COMMAND
(int)
MYSQLND_UH_MYSQLND_READ_DEFAULT_FILE
(int)
MYSQLND_UH_MYSQLND_READ_DEFAULT_GROUP
(int)
MYSQLND_UH_MYSQLND_SET_CHARSET_DIR
(int)
MYSQLND_UH_MYSQLND_SET_CHARSET_NAME
(int)
MYSQLND_UH_MYSQLND_OPT_LOCAL_INFILE
(int)
LOAD DATA LOCAL INFILE
use.
MYSQLND_UH_MYSQLND_OPT_PROTOCOL
(int)
MYSQLND_UH_MYSQLND_OPT_READ_TIMEOUT
(int)
MYSQLND_UH_MYSQLND_OPT_WRITE_TIMEOUT
(int)
MYSQLND_UH_MYSQLND_OPT_USE_RESULT
(int)
MYSQLND_UH_MYSQLND_OPT_USE_REMOTE_CONNECTION
(int)
MYSQLND_UH_MYSQLND_OPT_USE_EMBEDDED_CONNECTION
(int)
MYSQLND_UH_MYSQLND_OPT_GUESS_CONNECTION
(int)
MYSQLND_UH_MYSQLND_SET_CLIENT_IP
(int)
MYSQLND_UH_MYSQLND_SECURE_AUTH
(int)
MYSQLND_UH_MYSQLND_REPORT_DATA_TRUNCATION
(int)
MYSQLND_UH_MYSQLND_OPT_RECONNECT
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_VERIFY_SERVER_CERT
(int)
MYSQLND_UH_MYSQLND_OPT_NET_CMD_BUFFER_SIZE
(int)
MYSQLND_UH_MYSQLND_OPT_NET_READ_BUFFER_SIZE
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_KEY
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_CERT
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_CA
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_CAPATH
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_CIPHER
(int)
MYSQLND_UH_MYSQLND_OPT_SSL_PASSPHRASE
(int)
MYSQLND_UH_SERVER_OPTION_PLUGIN_DIR
(int)
MYSQLND_UH_SERVER_OPTION_DEFAULT_AUTH
(int)
MYSQLND_UH_SERVER_OPTION_SET_CLIENT_IP
(int)
MYSQLND_UH_MYSQLND_OPT_MAX_ALLOWED_PACKET
(int)
PHP 5.4.0
.
MYSQLND_UH_MYSQLND_OPT_AUTH_PROTOCOL
(int)
PHP 5.4.0
.
MYSQLND_UH_MYSQLND_OPT_INT_AND_FLOAT_NATIVE
(int)
Other
The plugins version number can be obtained using
MYSQLND_UH_VERSION
or
MYSQLND_UH_VERSION_ID
.
MYSQLND_UH_VERSION
is the string representation of the numerical version number
MYSQLND_UH_VERSION_ID
, which is an integer such as 10000.
Developers can calculate the version number as follows.
Version (part) | Example |
---|---|
Major*10000 | 1*10000 = 10000 |
Minor*100 | 0*100 = 0 |
Patch | 0 = 0 |
MYSQLND_UH_VERSION_ID |
10000 |
MYSQLND_UH_VERSION
(string)
1.0.0-alpha.
MYSQLND_UH_VERSION_ID
(int)