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 0512 #1799

Merged
merged 4 commits into from
May 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
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
4 changes: 2 additions & 2 deletions docs-2.0/3.ngql-guide/1.nGQL-overview/1.overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ nebula> CREATE TAG IF NOT EXISTS player(name string, age int);

### 原生 nGQL 和 openCypher 的关系

原生 nGQL 是由 Nebula Graph 自行创造和实现的图查询语言。OpenCypher 是由 openCypher Implementers Group 组织所开源和维护的图查询语言,最新版本为 openCypher 9。
原生 nGQL 是由 Nebula Graph 自行创造和实现的图查询语言。openCypher 是由 openCypher Implementers Group 组织所开源和维护的图查询语言,最新版本为 openCypher 9。

由于 nGQL 语言部分兼容了 openCypher,这个部分在本文中称为 openCypher 兼容语句。

Expand Down Expand Up @@ -119,7 +119,7 @@ nebula> CREATE TAG IF NOT EXISTS player(name string, age int);
|相等运算符| `=` | `==` |
|数学求幂| `^` | 使用`pow(x, y)`替代`^`。 |
|边 Rank| 无此概念 | 用`@rank`设置。 |
|语句|-|不支持 openCypher 9 的所有 DML 语句(如`CREATE`、`MERGE`等),不支持所有的 DCL, 和支持部分 `MATCH`, `OPTIONAL MATCH` 语法和函数。 |
|语句|-|不支持 openCypher 9 的所有 DML 语句(如`CREATE`、`MERGE`等),不支持所有的 DCL,和支持部分 `MATCH`, `OPTIONAL MATCH` 语法和函数。 |
|语句文本换行 | 换行符 | `\` + 换行符 |
|Label 与 Tag 是不同的概念| Label 用于寻找点(点的索引)。 | Tag 用于定义点的一种类型及相应的属性,无索引功能。 |
| 预编译与参数化查询 | 支持 | 仅支持参数化查询。 |
Expand Down
7 changes: 4 additions & 3 deletions docs-2.0/3.ngql-guide/1.nGQL-overview/comments.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@

本文介绍 nGQL 中的注释方式。

## 历史版本兼容性

* Nebula Graph 1.x 支持四种注释方式:`#`、`--`、`//`、`/* */`。
* Nebula Graph 2.x 中,`--`不再是注释符。
!!! compatibility "历史版本兼容性"

- Nebula Graph 1.x 支持四种注释方式:`#`、`--`、`//`、`/* */`。
- Nebula Graph 2.x 中,`--`不再是注释符。

## Examples

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
```ngql
nebula> CREATE SPACE IF NOT EXISTS my_space (vid_type=FIXED_STRING(30));
nebula> use MY_SPACE;
[ERROR (-8)]: SpaceNotFound:
[ERROR (-1005)]: SpaceNotFound:
```

## 关键字不区分大小写
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

```ngql
nebula> CREATE TAG TAG(name string);
[ERROR (-7)]: SyntaxError: syntax error near `TAG'
[ERROR (-1004)]: SyntaxError: syntax error near `TAG'

nebula> CREATE TAG `TAG` (name string);
Execution succeeded
Expand Down