Newb to Neo4j, I was successfully able to leverage apoc.coll.avg , apoc.coll.min & apoc.coll.Max but I'm receiving an error when trying to use apoc.coll.runningTotal
WITH apoc.coll.runningTotal([1,2,3,4,5]) AS d RETURN d
Unknown function 'apoc.coll.runningTotal' (line 2, column 6 (offset: 18)) "WITH apoc.coll.runningTotal([1,2,3,4,5]) AS d"
It looks like it does not recognize that function. I would ask if you have apoc installed, but you said you successfully used the collection's min and max functions. Try running the following query to see if the apoc.coll.runningTotal function is in the list.
There are two versions of the APOC jar. One is a 'full' version and one is a 'core' version. I switched mine to 'core' and did not see the procedure in the list. Look in your plug-ins folder. The jar's name has 'core' in it.
If you have the core, I think you can remove it from the plug-ins folder and install the full version with the Neo4j Desktop under the 'plugins' tab.
Thanks a bunch! I currently using Neo4j through Aura and per the support team it's not supported. Do you recommend me to use another neo4j flavor? Once again I'm a newb to Neo4j.
that is a bummer. I created a cypher expression that will calculate the runningTotal for you. Here it is in an example. Use the expression on line 2 for calculating it.
with [1,2,3,5,10] as coll
with [i in range(1,size(coll)) | reduce(s=0,x in coll[..i]|s+x)] as runningTotal
return runningTotal