singlequery handles db requests where there's only one query, postit function now takes a the callback function as argument