From 5bae075d524212b3b6c9da965c9104993d15004d Mon Sep 17 00:00:00 2001 From: Robert Treat Date: Sun, 1 Feb 2015 14:38:01 -0500 Subject: [PATCH] Explicit Support for PG 9.4 --- classes/database/Connection.php | 3 ++- classes/database/Postgres.php | 4 ++-- classes/database/Postgres92.php | 4 ++-- classes/database/Postgres93.php | 30 ++++++++++++++++++++++++++++++ 4 files changed, 36 insertions(+), 5 deletions(-) create mode 100644 classes/database/Postgres93.php diff --git a/classes/database/Connection.php b/classes/database/Connection.php index a8e81b54..3a3e3d05 100755 --- a/classes/database/Connection.php +++ b/classes/database/Connection.php @@ -76,7 +76,8 @@ class Connection { // Detect version and choose appropriate database driver switch (substr($version,0,3)) { - case '9.3': return 'Postgres'; break; + case '9.4': return 'Postgres'; break; + case '9.3': return 'Postgres93'; break; case '9.2': return 'Postgres92'; break; case '9.1': return 'Postgres91'; break; case '9.0': return 'Postgres90'; break; diff --git a/classes/database/Postgres.php b/classes/database/Postgres.php index b31bc036..d01906bf 100755 --- a/classes/database/Postgres.php +++ b/classes/database/Postgres.php @@ -11,7 +11,7 @@ include_once('./classes/database/ADODB_base.php'); class Postgres extends ADODB_base { - var $major_version = 9.3; + var $major_version = 9.4; // Max object name length var $_maxNameLen = 63; // Store the current schema @@ -419,7 +419,7 @@ class Postgres extends ADODB_base { } function getHelpPages() { - include_once('./help/PostgresDoc93.php'); + include_once('./help/PostgresDoc94.php'); return $this->help_page; } diff --git a/classes/database/Postgres92.php b/classes/database/Postgres92.php index b67bfe07..d20b188a 100644 --- a/classes/database/Postgres92.php +++ b/classes/database/Postgres92.php @@ -5,9 +5,9 @@ * */ -include_once('./classes/database/Postgres.php'); +include_once('./classes/database/Postgres93.php'); -class Postgres92 extends Postgres { +class Postgres92 extends Postgres93 { var $major_version = 9.2; diff --git a/classes/database/Postgres93.php b/classes/database/Postgres93.php new file mode 100644 index 00000000..bcf7e411 --- /dev/null +++ b/classes/database/Postgres93.php @@ -0,0 +1,30 @@ +Postgres($conn); + } + + // Help functions + + function getHelpPages() { + include_once('./help/PostgresDoc93.php'); + return $this->help_page; + } + +} +?> -- 2.39.5