Optimizing the queries over to OneSky
Fixing typo in query