php8.5
Home/ Manual/ reference / pdo_dblib/ The Pdo\Dblib class

The Pdo\Dblib class

A PDO subclass representing a connection using the DBLib PDO driver.

Intro

A PDO subclass representing a connection using the DBLib PDO driver.

Class synopsis

PdoDblibextendsPDOInheritedConstantsConstantspublicconstintPdo\Dblib::ATTR_CONNECTION_TIMEOUTpublicconstintPdo\Dblib::ATTR_QUERY_TIMEOUTpublicconstboolPdo\Dblib::ATTR_STRINGIFY_UNIQUEIDENTIFIERpublicconstintPdo\Dblib::ATTR_VERSIONpublicconstintPdo\Dblib::ATTR_TDS_VERSIONpublicconstintPdo\Dblib::ATTR_SKIP_EMPTY_ROWSETSpublicconstboolPdo\Dblib::ATTR_DATETIME_CONVERTInheritedMethods

Predefined Constants

Pdo\Dblib::ATTR_CONNECTION_TIMEOUT
Pdo\Dblib::ATTR_QUERY_TIMEOUT
Pdo\Dblib::ATTR_STRINGIFY_UNIQUEIDENTIFIER

As of PHP 8.4.0 this constant is typed as bool; previously, it was typed as int.

Pdo\Dblib::ATTR_VERSION
Pdo\Dblib::ATTR_TDS_VERSION
Pdo\Dblib::ATTR_SKIP_EMPTY_ROWSETS
Pdo\Dblib::ATTR_DATETIME_CONVERT

This connection attribute controls the format of strings for datetime types. When this is false, PDO_DBLIB will return a datetime type as a string in the format that SQL Server returns it in (i.e. "2017-10-27 10:22:44"). When true, PDO_DBLIB will convert the datetime type into a string using a user-defined or locale format, as specified in the FreeTDS locales.conf file. By default, this attribute is false.

As of PHP 8.4.0 this constant is typed as bool; previously, it was typed as int.

Source: reference/pdo_dblib/pdo-dblib.xml · from the official PHP manual (php/doc-en)