Merge "Use pg_result_error, not pg_last_error, as the latter gives false negatives."
This commit is contained in:
commit
8eac2feedb
1 changed files with 3 additions and 3 deletions
|
|
@ -838,7 +838,7 @@ __INDEXATTR__;
|
|||
$tempres = (bool)$this->query( $tempsql, $fname, $savepoint );
|
||||
|
||||
if ( $savepoint ) {
|
||||
$bar = pg_last_error();
|
||||
$bar = pg_result_error( $this->mLastResult );
|
||||
if ( $bar != false ) {
|
||||
$savepoint->rollback();
|
||||
} else {
|
||||
|
|
@ -863,7 +863,7 @@ __INDEXATTR__;
|
|||
$sql .= '(' . $this->makeList( $args ) . ')';
|
||||
$res = (bool)$this->query( $sql, $fname, $savepoint );
|
||||
if ( $savepoint ) {
|
||||
$bar = pg_last_error();
|
||||
$bar = pg_result_error( $this->mLastResult );
|
||||
if ( $bar != false ) {
|
||||
$savepoint->rollback();
|
||||
} else {
|
||||
|
|
@ -946,7 +946,7 @@ __INDEXATTR__;
|
|||
|
||||
$res = (bool)$this->query( $sql, $fname, $savepoint );
|
||||
if ( $savepoint ) {
|
||||
$bar = pg_last_error();
|
||||
$bar = pg_result_error( $this->mLastResult );
|
||||
if ( $bar != false ) {
|
||||
$savepoint->rollback();
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue