[英]append function doesn't work as expected (arangodb)
These are few queries which I executed and the results. 这些是我执行的少数查询和结果。 The fourth one throws error.
第四个抛出错误。
LET doc = DOCUMENT("sample/xyz")
RETURN doc.t==null
result: True (as key xyz doesn't exist) 结果:True(因为键xyz不存在)
RETURN append(null,[1,2,2],true)
result : [1,2] (unique values appended to empty list) 结果:[1,2](唯一值附加到空列表)
LET doc = DOCUMENT("sample/xyz")
return append(doc.t,[1,2,2])
result : [1,2,2] ([1,2,2] appended to empty list) 结果:[1,2,2]([1,2,2]附加到空列表)
LET doc = DOCUMENT("sample/xyz")
RETURN append(doc.t,[1,2,2],True)
throws error whereas doc.t should evaluate to null and result should be [1,2] . 引发错误,而doc.t应评估为null ,结果应为[1,2] 。
The error that I got is here : 我得到的错误在这里:
Query: Expecting type Array or Object (while executing) (exception location: /var/lib/jenkins/workspace/ArangoDB_Release/arangod/RestHandler/RestCursorHandler.cpp:131)
Sorry for getting back to you that late. 很抱歉这么晚回复您。 This used to be an issue with ArangoDB 3.0;
这曾经是ArangoDB 3.0的问题; It doesn't happen with ArangoDB 3.1 / 3.2
使用ArangoDB 3.1 / 3.2不会发生这种情况
I've added a test for this too, so it won't change in the future again. 我也为此添加了一个测试,因此将来不会再次更改。
In general, please file issues via github issues, not as a stackoverflow question. 通常,请通过github问题提交问题,而不是通过stackoverflow问题提交。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.