Добро пожаловать на форум PHP программистов!
За последние 24 часа нас посетили 19808 программистов и 1626 роботов. Сейчас ищут 1525 программистов ...

DB_common::provides()

Вернуться к: DB

DB_common::provides()

DB_common::provides() – Checks if the DBMS supports a particular feature

Synopsis

boolean provides ( string $feature )

Checks if a feature is available for the chosen database type.

Parameter

string $feature

the feature to check

Possible values are:
$feature value Meaning
prepare The database does a pre-check of the SQL statement
pconnect The database supports persistent connections
transactions The database supports transactions
limit The database supports LIMITed SELECT statements

Return value

boolean - TRUE if the feature is supported

Note

This function can not be called statically.

The provided information are only hints. Check the documentation of your database system for the real supported features. I.e. MySQL supports transactions, but not for every table type.

Example

Using provides()

<?php
// Once you have a valid DB object named $db...
if ($db->provides('pconnect')) {
    echo 
"Persistent connections are allowed.\n";
}
?>


Вернуться к: DB

© 2025 «PHP.RU — Сообщество PHP-Программистов»
Главная | Форум | Реклама на сайте | Контакты VIP Сувениры
Разработка компании ODware