Hi
Ya this is the very common error whenever you left your database
open....closing the db doesn't mean you write db.close() at the
end...you should write this in try{ }catch() block. ....because
sometimes what happen...if error exists the code stops there and the
db left opened...so you need to do this db.close() in catch block
also..............I resolved all my connections and lock errors like
this........One more point is that you should close the db there it
self wherever you opened...i.e. in same function
probably...................so just try this simple db connection good
practices and all your errors will be resolved..................All
the Best....