Removing query that is not used