fixed the queries, and added new class