Fix SelectQuery