odbc_statistics
(PHP 4, PHP 5)
odbc_statistics — Retrieve statistics about a table
Description
resource odbc_statistics
( resource $connection_id
, string $qualifier
, string $owner
, string $table_name
, int $unique
, int $accuracy
)
Get statistics about a table and its indexes. Returns an ODBC result identifier or FALSE on failure.
The result set has the following columns:
- TABLE_QUALIFIER
- TABLE_OWNER
- TABLE_NAME
- NON_UNIQUE
- INDEX_QUALIFIER
- INDEX_NAME
- TYPE
- SEQ_IN_INDEX
- COLUMN_NAME
- COLLATION
- CARDINALITY
- PAGES
- FILTER_CONDITION
The result set is ordered by NON_UNIQUE, TYPE, INDEX_QUALIFIER, INDEX_NAME and SEQ_IN_INDEX.
- PHP Руководство
- Функции по категориям
- Индекс функций
- Справочник функций
- Расширения для работы с базами данных
- Уровни абстракции
- ODBC (Unified)
- odbc_autocommit
- odbc_binmode
- odbc_close_all
- odbc_close
- odbc_columnprivileges
- odbc_columns
- odbc_commit
- odbc_connect
- odbc_cursor
- odbc_data_source
- odbc_do
- odbc_error
- odbc_errormsg
- odbc_exec
- odbc_execute
- odbc_fetch_array
- odbc_fetch_into
- odbc_fetch_object
- odbc_fetch_row
- odbc_field_len
- odbc_field_name
- odbc_field_num
- odbc_field_precision
- odbc_field_scale
- odbc_field_type
- odbc_foreignkeys
- odbc_free_result
- odbc_gettypeinfo
- odbc_longreadlen
- odbc_next_result
- odbc_num_fields
- odbc_num_rows
- odbc_pconnect
- odbc_prepare
- odbc_primarykeys
- odbc_procedurecolumns
- odbc_procedures
- odbc_result_all
- odbc_result
- odbc_rollback
- odbc_setoption
- odbc_specialcolumns
- odbc_statistics
- odbc_tableprivileges
- odbc_tables
Коментарии
A couple of the function parameters are undefined:
unique - determines whether you want to return just unique indexes or all indexes. Use SQL_INDEX_UNIQUE or SQL_INDEX_ALL for this parameter
accuracy - whether you wan to return everything there is to know about the table or just what information is readily available. Use SQL_ENSURE or SQL_QUICK for this parameter
For a bit more info about this function see the ODBC function SQLStatistics() at http://msdn.microsoft.com/en-us/library/ms711022(v=vs.85).aspx