@@ 900-907 (lines=8) @@ | ||
897 | $stmt = $this->Prepare($sql); |
|
898 | $this->BeginTrans(); |
|
899 | $rs = $this->Execute($stmt, $inputarr); |
|
900 | if (0 != $this->ErrorNo()) { |
|
901 | // Log to error log file |
|
902 | error_log('ErrorNo: ' . $this->ErrorNo() |
|
903 | . "\nErrorMsg: " . $this->ErrorMsg() |
|
904 | ); |
|
905 | $this->RollbackTrans(); |
|
906 | return -1; |
|
907 | } |
|
908 | $this->CommitTrans(); |
|
909 | return $rs; |
|
910 | } // end of PExecute |
|
@@ 1132-1143 (lines=12) @@ | ||
1129 | return -1; |
|
1130 | } |
|
1131 | // Any error ? |
|
1132 | if (0 != $this->ErrorNo()) { |
|
1133 | // Log to error log file |
|
1134 | error_log('ErrorNo: ' . $this->ErrorNo() |
|
1135 | . "\nErrorMsg: " . $this->ErrorMsg() |
|
1136 | ); |
|
1137 | $this->RollbackTrans(); |
|
1138 | return -1; |
|
1139 | } |
|
1140 | else { |
|
1141 | $this->CommitTrans(); |
|
1142 | return count($data); |
|
1143 | } |
|
1144 | } |
|
1145 | else |
|
1146 | return -1; |