Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update 2.match.md #2385

Merged
merged 7 commits into from
Dec 14, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ MATCH <pattern> [<clause_1>] RETURN <output> [<clause_2>];

- 当遍历所有点边时,例如`MATCH (v) RETURN v LIMIT N`,不需要创建索引,但必须使用`LIMIT`限制输出结果数量。

- 当遍历指定 Tag 的点或指定 Edge Type 的边时,例如`MATCH (v:player) RETURN v LIMIT N`,不需要创建索引,但必须使用`LIMIT`限制输出结果数量。
- 当遍历指定 Tag 的点或指定 Edge Type 的边时,例如`MATCH (v:player) RETURN v LIMIT N`或`MATCH ()-[e:follow]->() RETURN e LIMIT N`,不需要创建索引,但必须使用`LIMIT`限制输出结果数量。

!!! note

Expand All @@ -41,6 +41,11 @@ MATCH <pattern> [<clause_1>] RETURN <output> [<clause_2>];
!!! compatibility "历史版本兼容性"

从 3.0.0 版本开始,为了区别不同 Tag 的属性,返回属性时必须额外指定 Tag 名称。即从`RETURN <变量名>.<属性名>`改为`RETURN <变量名>.<Tag名>.<属性名>`。

!!! caution

在不创建索引的情况下,可能会出现不符合直觉的返回结果,建议使用`Match`语句时创建**至少**一个[索引](../14.native-index-statements/1.create-native-index.md)。


## 示例

Expand Down