Add query affinitic refs #5831