summaryrefslogtreecommitdiff
path: root/ext/pdo_firebird/pdo_firebird.c
diff options
context:
space:
mode:
authorLars Westermann <lwe@php.net>2007-10-30 16:28:47 +0000
committerLars Westermann <lwe@php.net>2007-10-30 16:28:47 +0000
commitaa6c5a81f9925ead13ec8b06683f31a1069639b1 (patch)
treeecd9a9ba49fc78e14164b09d81051df9a76454f8 /ext/pdo_firebird/pdo_firebird.c
parent1ac482c84bec1198d4649f92ba6a99ff4a535a1a (diff)
downloadphp-git-aa6c5a81f9925ead13ec8b06683f31a1069639b1.tar.gz
[DOC] Added 3 firebird specific attributes that can be set via
PDO::setAttribute() to control formatting of date/timestamp columns: PDO::FB_ATTR_DATE_FORMAT, PDO::FB_ATTR_TIME_FORMAT and PDO::FB_ATTR_TIMESTAMP_FORMAT. These attributes are strftime format strings, and operate in the same way as the ibase.dateformat, ibase.timeformat and ibase.timestampformat ini options. (related to bug #36128, Interbase PDO)
Diffstat (limited to 'ext/pdo_firebird/pdo_firebird.c')
-rw-r--r--ext/pdo_firebird/pdo_firebird.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/pdo_firebird/pdo_firebird.c b/ext/pdo_firebird/pdo_firebird.c
index ac09b5bc89..f69a2b3be0 100644
--- a/ext/pdo_firebird/pdo_firebird.c
+++ b/ext/pdo_firebird/pdo_firebird.c
@@ -55,6 +55,10 @@ ZEND_GET_MODULE(pdo_firebird)
PHP_MINIT_FUNCTION(pdo_firebird) /* {{{ */
{
+ REGISTER_PDO_CLASS_CONST_LONG("FB_ATTR_DATE_FORMAT", (long) PDO_FB_ATTR_DATE_FORMAT);
+ REGISTER_PDO_CLASS_CONST_LONG("FB_ATTR_TIME_FORMAT", (long) PDO_FB_ATTR_TIME_FORMAT);
+ REGISTER_PDO_CLASS_CONST_LONG("FB_ATTR_TIMESTAMP_FORMAT", (long) PDO_FB_ATTR_TIMESTAMP_FORMAT);
+
php_pdo_register_driver(&pdo_firebird_driver);
return SUCCESS;