Fix bug in group queries related to node/instance fields