Fix on queries