Skip to content

Commit c9a9cdc

Browse files
committed
Fix parametrized stream for mutated properties
1 parent 324d427 commit c9a9cdc

File tree

1 file changed

+10
-9
lines changed

1 file changed

+10
-9
lines changed
Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
// Read a property from the projection into the Graph. Variables: dependencies_projection, dependencies_projection_write_property
22

3-
CALL gds.fastRP.stream(
4-
$dependencies_projection + '-without-empty', {
5-
embeddingDimension: toInteger($dependencies_projection_embedding_dimension)
6-
,relationshipWeightProperty: $dependencies_projection_weight_property
7-
}
3+
CALL gds.graph.nodeProperties.stream(
4+
$dependencies_projection + '-without-empty'
5+
,[$dependencies_projection_write_property]
86
)
9-
YIELD nodeId, embedding
7+
YIELD nodeId, nodeProperty, propertyValue
108
WITH gds.util.asNode(nodeId) AS codeUnit
11-
,embedding
9+
,nodeProperty AS propertyName
10+
,propertyValue
1211
OPTIONAL MATCH (artifact:Artifact)-[:CONTAINS]->(codeUnit)
1312
RETURN DISTINCT coalesce(codeUnit.fqn, codeUnit.fileName, codeUnit.name) AS codeUnitName
13+
,coalesce(replace(last(split(codeUnit.fileName, '/')), '.jar', ''), codeUnit.name) AS shortCodeUnitName
14+
,propertyName
15+
,propertyValue
1416
,coalesce(codeUnit.leidenCommunityId, 0) AS communityId
1517
,coalesce(codeUnit.centralityPageRank, 0.01) AS centrality
16-
,replace(last(split(artifact.fileName, '/')), '.jar', '') AS artifactName
17-
,embedding
18+
,replace(last(split(artifact.fileName, '/')), '.jar', '') AS artifactName

0 commit comments

Comments
 (0)