Fix: Save error only if it's not error to say there is error.
This commit is contained in:
parent
29d90f3713
commit
1e4efb9e16
@ -556,9 +556,12 @@ class DoliDBPgsql
|
|||||||
{
|
{
|
||||||
if (! $ret)
|
if (! $ret)
|
||||||
{
|
{
|
||||||
$this->lastqueryerror = $query;
|
if ($this->errno() != 'DB_ERROR_25P02')
|
||||||
$this->lasterror = $this->error();
|
{
|
||||||
$this->lasterrno = $this->errno();
|
$this->lastqueryerror = $query;
|
||||||
|
$this->lasterror = $this->error();
|
||||||
|
$this->lasterrno = $this->errno();
|
||||||
|
}
|
||||||
dol_syslog(get_class($this)."::query SQL error: ".$query." ".$this->lasterrno, LOG_WARNING);
|
dol_syslog(get_class($this)."::query SQL error: ".$query." ".$this->lasterrno, LOG_WARNING);
|
||||||
//print "\n>> ".$query."<br>\n";
|
//print "\n>> ".$query."<br>\n";
|
||||||
//print '>> '.$this->lasterrno.' - '.$this->lasterror.' - '.$this->lastqueryerror."<br>\n";
|
//print '>> '.$this->lasterrno.' - '.$this->lasterror.' - '.$this->lastqueryerror."<br>\n";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user