wrapped all sqlite calls in exception safe methods. Need to cleanup and move to common. (wip)