Finishing sqlite abstraction