-
-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SQLite error handling problem when using prepared queries. #37
Comments
I'm able to confirm this bug, and have located the source, at https://github.com/fukamachi/cl-dbi/blob/master/src/dbd/sqlite3.lisp#L74: (when (handler-case (step-statement prepared)
(sqlite-error (e)
@ignore e
nil))
Then, the I don't see any logical reason for the inclusion of the EDIT: I do not suggest the workaround proposed by @heegaiximephoomeeghahyaiseekh; it results in odd behaviour relating to |
I can confirm this bug still exists as of 20180430. |
I investigated things a bit further, since removing the
|
Slight correction to the above: it is probably valid to still have |
When certain errors occur while executing an SQLite prepared query, no condition is
signalled until the next time the statement is used. As a result, I have to add special
SQLite-specific code to my project to get correct results.
Reproduction:
Solution: Call
sqlite:reset-statement
after using the statement, and beforedbi:execute
returns.Workaround: End users can add the following method to their project to make
the errors throw as soon as the failing query returns.
The text was updated successfully, but these errors were encountered: