Fixed a query