only check for postgres major and minor version

fixes #192
This commit is contained in:
Sarah Hoffmann 2014-10-29 21:04:28 +01:00
parent ed4e46c3d9
commit 7eb263a3a4

View File

@ -110,7 +110,7 @@
$oDB =& getDB();
$sVersionString = $oDB->getOne('select version()');
preg_match('#PostgreSQL ([0-9]+)[.]([0-9]+)[.]([0-9]+) #', $sVersionString, $aMatches);
preg_match('#PostgreSQL ([0-9]+)[.]([0-9]+)[^0-9]#', $sVersionString, $aMatches);
if (CONST_Postgresql_Version != $aMatches[1].'.'.$aMatches[2])
{
echo "ERROR: PostgreSQL version is not correct. Expected ".CONST_Postgresql_Version." found ".$aMatches[1].'.'.$aMatches[2]."\n";