From 05fddc8eb8ee343545022ebc063d995dee3bdd10 Mon Sep 17 00:00:00 2001 From: cooper-lzy <78672629+cooper-lzy@users.noreply.github.com> Date: Thu, 10 Mar 2022 10:33:12 +0800 Subject: [PATCH] Remove the upper limitation of path length --- docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md b/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md index 27337fe6af0..6b012f47f9f 100644 --- a/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md +++ b/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md @@ -480,16 +480,16 @@ nebula> MATCH (v:player{name:"Tim Duncan"}) -[*0]-> (v2) \ ### Match variable-length paths -You can use the `:*[minHop]..` pattern to match variable-length paths. +You can use the `:*[minHop]..[maxHop]` pattern to match variable-length paths. |Parameter|Description| |-|-| |`minHop`|Optional. It represents the minimum length of the path. `minHop` must be a non-negative integer. The default value is 1.| -|`maxHop`|Required. It represents the maximum length of the path. `maxHop` must be a non-negative integer. It has no default value.| +|`maxHop`|Optional. It represents the maximum length of the path. `maxHop` must be a non-negative integer. It has no default value.| !!! compatibility "OpenCypher compatibility" - In openCypher, `maxHop` is optional and defaults to infinity. When no bounds are given, `..` can be omitted. However, in nGQL, `maxHop` is required. And `..` cannot be omitted. + In openCypher, when `minHop` is not set, `..` can be omitted. However, in nGQL, `..` cannot be omitted. ```ngql nebula> MATCH p=(v:player{name:"Tim Duncan"})-[e:follow*1..3]->(v2) \