以下代码1.1版本执行没有问题:(1.1版本返回了VertexID字段 是我需要用到的)
go from 362050 over edge_type1 yield edge_type1._dst as id | go from $-.id over edge_type1 YIELD edge_type1._src,edge_type1._dst as dst | GROUP BY $-.dst yield $-.dst as id,count(1) as count | FETCH PROP ON tag1 $-.id YIELD tag1.name,$-.count as count | order by $-.count desc;
在2 nightly下执行报错
错误信息:
SemanticError: Unsupported input/variable property expression in yield.
错误原因推测:
GROUP BY $-.dst yield $-.dst as id,count(1) as count | FETCH PROP ON tag1 $-.id YIELD tag1.name,$-.count as count
yield获取不到$-.count内容。
go from 362050 over edge_type1 yield edge_type1._dst as id | go from $-.id over edge_type1 YIELD edge_type1._src, $$.tag1.name as name | GROUP BY $-.name yield $-.name as id,count(1) as count | order by $-.count desc;
go from 362050 over edge_type1 yield edge_type1._dst as id | go from $-.id over edge_type1 YIELD edge_type1._src, edge_type1._dst as dst,$$.tag1.name as name | GROUP BY $-.dst, $-.name yield $-.dst, $-.name as id,count(1) as count | order by $-.count desc;