Fixed `sqlite.query` bug & included error reasons