start={A.*};
SetAccum<VERTEX> @Xs;
MaxAccum<VERTEX> @Y
// A->X is an n…n relationship
start = select a from start:a-()->X:x
accum a.@Xs += x;
// A->Y is an 1…n relationship
Ys = select y from start:a-()->Y:y
accum y.@Y += a;
// now each c contains an A who has a set of X;
// Y->X is an n…1 relationship
result = select x from Ys:y-()->X:x
// now I want to do...
// error query at present
if y.@Y.@Xs.contains(x) then
// do something to tag the accepted x
end;
When mouse cursor is over the red text, reports:
no viable alternative at input ‘y.@y.@Xs’
no viable alternative at input ‘.@Xs’
How to solve this? Thanks!