- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我正在尝试获取从基节点到其根节点的路径作为 1 行。 Cypher 查询如下所示:
start n = node:node_auto_index(Name = "user1") match path = (n-[r:IS_MEMBER_OF_GROUP*]->b) return last(collect(distinct path));
var k = clientConnection.Cypher
.Start(new { n = "node:node_auto_index(Name = 'user1')" })
.Match("path = (n-[r:IS_MEMBER_OF_GROUP*]->b)")
.ReturnDistinct<Node<Principles>>("last(collect(path))").Results;
{"Value cannot be null.\r\nParameter name: uriString"}
Neo4jClient encountered an exception while deserializing the response from the server. This is likely a bug in Neo4jClient.
Please open an issue at https://bitbucket.org/Readify/neo4jclient/issues/new
To get a reply, and track your issue, ensure you are logged in on BitBucket before submitting.
Include the full text of this exception, including this message, the stack trace, and all of the inner exception details.
Include the full type definition of Neo4jClient.Node`1[[IQS_Neo4j_TestGraph.Nodes.Principles, IQS Neo4j TestGraph, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].
Include this raw JSON, with any sensitive values replaced with non-sensitive equivalents:
{
"columns" : [ "last(collect(path))" ],
"data" : [ [ {
"start" : "http://localhost:7474/db/data/node/3907",
"nodes" : [ "http://localhost:7474/db/data/node/3907", "http://localhost:7474/db/data/node/3906", "http://localhost:7474/db/data/node/3905", "http://localhost:7474/db/data/node/3904" ],
"length" : 3,
"relationships" : [ "http://localhost:7474/db/data/relationship/4761", "http://localhost:7474/db/data/relationship/4762", "http://localhost:7474/db/data/relationship/4763" ],
"end" : "http://localhost:7474/db/data/node/3904"
} ] ]
}
最佳答案
好吧,您返回的东西是 PathsResult
不是 Node<>
,因此如果您将查询更改为:
var k = clientConnection.Cypher
.Start(new { n = "node:node_auto_index(Name = 'user1')" })
.Match("path = (n-[r:IS_MEMBER_OF_GROUP*]->b)")
.ReturnDistinct<PathsResult>("last(collect(path))").Results; //<-- Change here
start
通过执行以下操作使其使用参数:
.Start(new { n = Node.ByIndexLookup("node_auto_index", "Name", "user1")})
关于neo4j - Cypher 到 Neo4JClient 不同收集,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18779512/
这就是我正在尝试的: match (e:Person) - [r] - (f:Person) where (count(r) > 5 AND count (r) 5 and cnt (m:Perso
每个熟悉 MySQL 的人都可能使用过 mysqldump 命令,它可以生成一个 SQL 语句文件,代表 MySQL 数据库中的模式和数据。这些 SQL 文本文件通常用于多种用途:备份、播种副本、在安
我想了解Spring data neo4j框架中的neo4j dsl推荐。 到目前为止,我曾经创建从 GraphRepository、NamedIndexRepository 等扩展的存储库接口(in
我正在尝试使用 ipython-cypher 在 Python 程序中运行 Neo4j Cypher 查询(并返回 Pandas 数据帧)。使用 IPython Notebook 时,我可以轻松建立连
Neo4j 密码查询collect() 在结果中返回数组。为了迭代它,我们需要将它添加到 arrayList 中。我们之前使用的流程没有帮助我们并抛出异常。 以前的代码:- public Strin
假设您有一个满足以下方案的数据库: (person {name:string, budget:int}) (person)-[:FRIEND]-(person) 如何在 Cypher 中查询以下内容?
{ "identity": 7, "labels": [ "Parent" ], "properties": { "name": "fo
我有一个 Cypher 查询,它返回两个 Tag 节点之间的 TagSynonym 节点: MATCH (t:Tag)(s:Tag) WHERE t.id = {tagId} AND s.id = {
我在一个看似简单的查询上失败了。 算法: 按某个值(desc)对节点进行排序: MATCH (n) WHERE has(n.II_VAL) WITH n, n.II_VAL as ShInflInd
我的 Neo4j 实例上的 Cypher 查询有问题。 我有以下图形结构: (d:Document)-->(t:Token)-->(l:Lemma) Document 可以与许多 Token 有传出关
我需要为给定的关系类型设置某种唯一约束。 (a)-[:RELATION]->(b) 为了实现这一点,我正在使用 CREATE UNIQUE (a)-[:RELATION]->(b) 在并发环境中,如果
我找不到类似的帖子,所以如果你已经知道一个或者我的问题不合适,请告诉我。 我有这个查询 MATCH (t:Taxi {name:'Taxi1813'}) (g2:Grid)-[r:TO*1..
我有以下密码查询,它返回特定节点的所有(进出)关系: START s=node(1) MATCH s(t) RETURN type(r) as RelationshipType, ....... 现在
我正在尝试从全局网络(特定节点的子网络到特定深度)中提取子图。 该网络由标记为 Account 的节点组成,其属性为 iban,关系为 TRANSFER_TO_AGG . 密码语法如下: MATCH
我正在使用 Cypher,我需要构建一个如下所示的查询 (A) ----e1----(B) \ | \ | e3 e2
我的问题是为什么WHERE运算符(operator)的工作速度没有预期的那么快? 考虑我有 7 个节点,标签为 Consumer .这是一些示例数据... MERGE (c:Consumer {mob
我在尝试在我的 Neo4j 中实现搜索时遇到了一个有趣的问题。 D B。我想在任何节点的属性中搜索某个短语(也允许部分匹配)。这必须是通用的并且适用于所有节点类型和标签,因此我无法搜索预定义的属性列表
我是 Neo4j 的新手,目前正在玩这个树结构: 黄色框中的数字是关系CHILD_OF 上名为order 的属性。 我的目标是 a) 通过此属性而不是通过定向关系(例如 LEFT、RIGHT 或 IS
这里属性 r.weight 中的值是一个字符串。我尝试了以下可能性将其转换为整数, INT(r.weight) Integer.parseInt(r.weight) convert(INT,r.wei
我有一个看起来像这样的 neo4j 图: 节点: 蓝色节点:账号 红色节点:电话号码 绿色节点:邮箱 图形设计: (:PhoneNumber) -[:PART_OF]->(:Account) (:Em
我是一名优秀的程序员,十分优秀!