generating do clauses
play nicely with querystrings