Include an SQL state when throwing an SQLException during checkClosed

This patch includes an SQL error code, that provides a better indicator to
consumers to retry. Otherwise, the exception is too bland and matching on
the string is not the best kind of API.

Signed-off-by: Ken Barber <ken@bob.sh>
Merge pull request #27 from kbarber/include_sqlstate_when_throwing_from_checkClosed

Include an SQL state when throwing an SQLException during checkClosed