add historicTask query