Fixed incorrect query.