Add showQuery from issue #695, this can be used for debugging purposes and acts as a helper function for a database connection