Add Count and Document SQLite integration tests
This commit is contained in:
@@ -43,7 +43,12 @@ class Custom
|
||||
$stmt->bindValue($key, $value, $dataType);
|
||||
}
|
||||
if ($debug) echo '<pre>SQL: ' . $stmt->queryString . '</pre>';
|
||||
if ($stmt->execute()) return $stmt;
|
||||
try {
|
||||
if ($stmt->execute()) return $stmt;
|
||||
} catch (PDOException $ex) {
|
||||
$keyword = explode(' ', $query, 2)[0];
|
||||
throw new DocumentException("Error executing $keyword statement: " . $stmt->errorCode(), previous: $ex);
|
||||
}
|
||||
$keyword = explode(' ', $query, 2)[0];
|
||||
throw new DocumentException("Error executing $keyword statement: " . $stmt->errorCode());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user