make callback and format parameter for mysql_tquery and _pquery optional