move queries to sub package