Star

match语句执行结果问题

  • Nebula 版本:v2.0.0-rc1
match (v1:vertexs) - [e:relations] - (v2:vertexs) where id(v1) == "id1" return e

结果为空

match (v1:vertexs) - [e:relations] - (v2:vertexs) where id(v2) == "id1" return e

结果正常
在不指定方向的时候这两个语句的结果不应该是一样的吗?为什么只有第二个有结果?

我们的 openCypher 目前还在逐渐完善中,所以麻烦在问题的正文补充下你使用的 Nebula 的版本号

可以在语句前面加个profile看下生成的执行计划吗? 截个图。 我本地测试这两种结果是一样的

v2.0.0-RC1以前的版本会有这个bug, 之后已经修复了

好的 請問在哪看具體的版本? 還有正式版是這周末發布嗎?

用的是docker鏡像 v2-nightly

你哪天pull的镜像?这个问题是12.29号之后修复的。 如果你用的版本不是太旧的话, 可以进如console 执行下show hosts graph, 有个字段叫git sha info

用的的v2.0.0-rc1版本 info sha 是e36e960
1月14 pull的鏡像

環境不太方便截圖
我看了兩個執行計劃 基本完全一樣
只有第16步

outputVar:[
{
"colNames":[
"v1",
"e",
"v2",
"__COL_0"
],
"name":"__Filter_16",
"type":"DATASET"
}
]
inputVar:__filter_15
condition:(id($v1)==ecc81a03c24e40d886f8a1e3dee03125)

一個是v2 一個是v1
之前的過濾結果數量完全一樣

能把两个的完整的执行计划截图发下吗

你有没有更新最新的 v2-nightly 尝试?我在本地验证的结果如下:

(fass@nebula) [nba]> match (v:player)-[e:like]-(v2:player) where id(v)=="Tim Duncan" return e
+-------------------------------------------------------------+
| e                                                           |
+-------------------------------------------------------------+
| [:like "Aron Baynes"->"Tim Duncan" @0 {likeness: 80}]       |
+-------------------------------------------------------------+
| [:like "Boris Diaw"->"Tim Duncan" @0 {likeness: 80}]        |
+-------------------------------------------------------------+
| [:like "Danny Green"->"Tim Duncan" @0 {likeness: 70}]       |
+-------------------------------------------------------------+
| [:like "Dejounte Murray"->"Tim Duncan" @0 {likeness: 99}]   |
+-------------------------------------------------------------+
| [:like "LaMarcus Aldridge"->"Tim Duncan" @0 {likeness: 75}] |
+-------------------------------------------------------------+
| [:like "Manu Ginobili"->"Tim Duncan" @0 {likeness: 90}]     |
+-------------------------------------------------------------+
| [:like "Marco Belinelli"->"Tim Duncan" @0 {likeness: 55}]   |
+-------------------------------------------------------------+
| [:like "Shaquile O'Neal"->"Tim Duncan" @0 {likeness: 80}]   |
+-------------------------------------------------------------+
| [:like "Tiago Splitter"->"Tim Duncan" @0 {likeness: 80}]    |
+-------------------------------------------------------------+
| [:like "Tony Parker"->"Tim Duncan" @0 {likeness: 95}]       |
+-------------------------------------------------------------+
| [:like "Tim Duncan"->"Manu Ginobili" @0 {likeness: 95}]     |
+-------------------------------------------------------------+
| [:like "Tim Duncan"->"Tony Parker" @0 {likeness: 95}]       |
+-------------------------------------------------------------+
Got 12 rows (time spent 279876/302946 us)

Thu, 04 Feb 2021 11:34:34 CST


(fass@nebula) [nba]> match (v:player)-[e:like]-(v2:player) where id(v2)=="Tim Duncan" return e
+-------------------------------------------------------------+
| e                                                           |
+-------------------------------------------------------------+
| [:like "Aron Baynes"->"Tim Duncan" @0 {likeness: 80}]       |
+-------------------------------------------------------------+
| [:like "Boris Diaw"->"Tim Duncan" @0 {likeness: 80}]        |
+-------------------------------------------------------------+
| [:like "Danny Green"->"Tim Duncan" @0 {likeness: 70}]       |
+-------------------------------------------------------------+
| [:like "Dejounte Murray"->"Tim Duncan" @0 {likeness: 99}]   |
+-------------------------------------------------------------+
| [:like "LaMarcus Aldridge"->"Tim Duncan" @0 {likeness: 75}] |
+-------------------------------------------------------------+
| [:like "Manu Ginobili"->"Tim Duncan" @0 {likeness: 90}]     |
+-------------------------------------------------------------+
| [:like "Marco Belinelli"->"Tim Duncan" @0 {likeness: 55}]   |
+-------------------------------------------------------------+
| [:like "Shaquile O'Neal"->"Tim Duncan" @0 {likeness: 80}]   |
+-------------------------------------------------------------+
| [:like "Tiago Splitter"->"Tim Duncan" @0 {likeness: 80}]    |
+-------------------------------------------------------------+
| [:like "Tony Parker"->"Tim Duncan" @0 {likeness: 95}]       |
+-------------------------------------------------------------+
| [:like "Tim Duncan"->"Manu Ginobili" @0 {likeness: 95}]     |
+-------------------------------------------------------------+
| [:like "Tim Duncan"->"Tony Parker" @0 {likeness: 95}]       |
+-------------------------------------------------------------+
Got 12 rows (time spent 183300/184879 us)

Thu, 04 Feb 2021 11:34:39 CST

浙ICP备20010487号