Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
08-17-2020 01:58 AM
Hi,
Looking at the Native Projection section on Neo4j Documentation, I have seen this example:
// will use nodes projected as 'Person' or 'City' in 'myGraph'
CALL gds.pageRank.stats('myGraph', {nodeLabels: ['Person', 'City']})
What is the correct syntax for projecting only the nodes that have both "Person" and "City" labels (as an use an AND between the labels and not an OR)?
Using gds.alpha.degree.stream (also with native projection), I have tried unsuccessfully:
CALL gds.alpha.degree.stream(
{nodeProjection: "label1":"label2",
relationshipProjection: "ENFORCES",
writeProperty: "PolicyDegree"})
MATCH (a:label1:label2)
WITH a as my_nodes
CALL gds.alpha.degree.stream(
{nodeProjection: my_nodes,
relationshipProjection: "ENFORCES",
writeProperty: "PolicyDegree"})
Many thanks!
All the sessions of the conference are now available online