Expanded on QueryBuilder (not finished)