I have a schema where 3 of its vertexes are:
Concept
Round
User
Concept links to Round, Round links to User.
I tried to expand/modify this working query:
CREATE QUERY GetConceptRounds(vertex<Concept> inputConcept) FOR GRAPH MyGraph {
Start = {inputConcept};
Rounds = SELECT t FROM Start:s-(Concept2Round:e)-Round:t;
PRINT Rounds;
}
to show all users linked to concepts via rounds, but obviously I failed. Can someone kindly advise how to revise this to pull users?
CREATE QUERY GetConceptRoundsUsers(vertex<Concept> inputConcept) FOR GRAPH MyGraph {
Start = {inputConcept};
Users = SELECT tU FROM Start:s-(<Concept2Round:e)-Round:t-(User2Round>:eU)-User:tU;
PRINT Users;
}
The above code was modeled after this example:
https://docs.tigergraph.com/intro/gsql-102/multiple-hop-pattern#multiple-hop-pattern-shortest-path-semantics
and this was the result:
and the error is:
<<<
This query does not conform to pre-v2 syntax.
If you intent to use the pattern match syntax, please specify the v2 syntax version by one of the methods below:
- Use syntax_version session variable (set syntax_version=“v2”)
- Add the syntax clause to query header, e.g. create query q() syntax(“v2”)
Thank you.