Tweaked the queries