nineinchnick / pdo_oci8
A PDO userspace driver for the Oracle database using the oci8 PHP module.
dev-master
2015-03-28 18:37 UTC
Requires
- php: >=5.4.0
This package is not auto-updated.
Last update: 2024-12-11 09:18:04 UTC
README
A PDO userspace driver for the Oracle database using the oci8 PHP module.
Based on ramsey/pdo_oci8
, yjeroen/oci8Pdo
and yajra/laravel-pdo-via-oci8
.
Installation
composer require nineinchnick\pdo_oci8
Usage
$tsn = <<<TSN
(
DESCRIPTION=(
ADDRESS_LIST=(
ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)
)
)(
CONNECT_DATA=(SID=XE)
)
)
TSN;
$dsn = "oci:dbname=$tsn;charset=AL32UTF8;";
$username = 'xe';
$password = 'xe';
$attributes = [];
$conn = new nineinchnick\pdo\Oci8($dsn, $username, $password, $attributes);