| @@ 536-552 (lines=17) @@ | ||
| 533 | ||
| 534 | $this->countQuery(); |
|
| 535 | ||
| 536 | if (0 != $this->conn->ErrorNo()) { |
|
| 537 | // @codeCoverageIgnoreStart |
|
| 538 | ||
| 539 | // Log error |
|
| 540 | trigger_error( |
|
| 541 | 'ErrorNo: ' . $this->conn->ErrorNo() |
|
| 542 | . "\nErrorMsg: " . $this->conn->ErrorMsg(), |
|
| 543 | E_USER_ERROR |
|
| 544 | ); |
|
| 545 | $this->conn->RollbackTrans(); |
|
| 546 | ||
| 547 | return -1; |
|
| 548 | ||
| 549 | // @codeCoverageIgnoreEnd |
|
| 550 | } else { |
|
| 551 | $this->conn->CommitTrans(); |
|
| 552 | ||
| 553 | return $rs; |
|
| 554 | } |
|
| 555 | } |
|
| @@ 1572-1585 (lines=14) @@ | ||
| 1569 | } |
|
| 1570 | ||
| 1571 | // Any other error ? |
|
| 1572 | if (0 != $this->conn->ErrorNo()) { |
|
| 1573 | // Log error |
|
| 1574 | trigger_error( |
|
| 1575 | 'ErrorNo: ' . $this->conn->ErrorNo() . "\n" . |
|
| 1576 | 'ErrorMsg: ' . $this->conn->ErrorMsg(), |
|
| 1577 | E_USER_WARNING |
|
| 1578 | ); |
|
| 1579 | $this->conn->RollbackTrans(); |
|
| 1580 | ||
| 1581 | return -1; |
|
| 1582 | ||
| 1583 | } else { |
|
| 1584 | $this->conn->CommitTrans(); |
|
| 1585 | ||
| 1586 | return count($data); |
|
| 1587 | } |
|
| 1588 | // @codeCoverageIgnoreEnd |
|