Template:OOKM car person, queries reified
questions from car |
---|
MATCH
(inst:Inst {name: 'Dodge'})
-[:INST]->
(parent:Class)
-[:SUB*0..]->
(ancestor:Class)
<-[:QUEST]-
(quest:Quest)
-[farQuestRel:QUEST]->
(:Class)
RETURN quest.name AS question, farQuestRel.name AS class, farQuestRel.cardinality AS cardinality;
╒═════════════════════╤════════╤═══════════╕
│question │class │cardinality│
╞═════════════════════╪════════╪═══════════╡
│"driver of car" │"person"│"0..1" │
├─────────────────────┼────────┼───────────┤
│"responsible for car"│"person"│2 │
└─────────────────────┴────────┴───────────┘ |
questions from person |
---|
The questions are the same for any person. Replace ╒═════════════════════╤═════╤═══════════╕
│question │class│cardinality│
╞═════════════════════╪═════╪═══════════╡
│"responsible for car"│"car"│"0..5" │
├─────────────────────┼─────┼───────────┤
│"driver of car" │"car"│"0..1" │
└─────────────────────┴─────┴───────────┘ |
answers | ||||||
---|---|---|---|---|---|---|
The answer query has not changed. It is like that for Marseille shown above.
|