Update the query class to have an orderBy data structure. Added constructors to allow building of a subquery and easier adding of where statements.