Skip to content

Commit ea8f02f

Browse files
authored
Update 3.go.md (#1132)
1 parent d1f642d commit ea8f02f

File tree

1 file changed

+7
-33
lines changed
  • docs-2.0/3.ngql-guide/7.general-query-statements

1 file changed

+7
-33
lines changed

docs-2.0/3.ngql-guide/7.general-query-statements/3.go.md

+7-33
Original file line numberDiff line numberDiff line change
@@ -152,9 +152,9 @@ nebula> GO FROM "player100" OVER follow REVERSELY \
152152
+---------------------+-----------------+
153153
| FriendOf | Team |
154154
+---------------------+-----------------+
155-
| "Danny Green" | "Spurs" |
156-
| "Danny Green" | "Cavaliers" |
157-
+---------------------+-----------------+
155+
| "Boris Diaw" | "Spurs" |
156+
| "Boris Diaw" | "Jazz" |
157+
| "Boris Diaw" | "Suns" |
158158
...
159159
160160
# 该MATCH查询与上一个GO查询具有相同的语义。
@@ -164,34 +164,9 @@ nebula> MATCH (v)<-[e:follow]- (v2)-[e2:serve]->(v3) \
164164
+---------------------+-----------------+
165165
| FriendOf | Team |
166166
+---------------------+-----------------+
167-
| "Tony Parker" | "Spurs" |
168-
| "Tony Parker" | "Hornets" |
169-
+---------------------+-----------------+
170-
...
171-
```
172-
173-
```ngql
174-
# 返回player102所有邻居点。
175-
nebula> GO FROM "player102" OVER follow \
176-
YIELD dst(edge) AS both;
177-
+-------------+
178-
| both |
179-
+-------------+
180-
| "player100" |
181-
| "player101" |
182-
+-------------+
183-
...
184-
185-
# 该MATCH查询与上一个GO查询具有相同的语义。
186-
nebula> MATCH (v) -[e:follow]-(v2) \
187-
WHERE id(v)== "player102" \
188-
RETURN id(v2) AS both;
189-
+-------------+
190-
| both |
191-
+-------------+
192-
| "player101" |
193-
| "player103" |
194-
+-------------+
167+
| "Boris Diaw" | "Spurs" |
168+
| "Boris Diaw" | "Jazz" |
169+
| "Boris Diaw" | "Suns" |
195170
...
196171
```
197172

@@ -204,7 +179,6 @@ nebula> GO 1 TO 2 STEPS FROM "player100" OVER follow \
204179
+-------------+
205180
| "player101" |
206181
| "player125" |
207-
+-------------+
208182
...
209183
210184
# 该MATCH查询与上一个GO查询具有相同的语义。
@@ -216,7 +190,7 @@ nebula> MATCH (v) -[e:follow*1..2]->(v2) \
216190
+-------------+
217191
| "player100" |
218192
| "player102" |
219-
+-------------+
193+
...
220194
```
221195

222196
```ngql

0 commit comments

Comments
 (0)