Thin database wrapper for php