You can do it using split on ":" toInt and multiplication on the parts It would be better if you also store the int value
Von meinem iPhone gesendet > Am 21.10.2014 um 02:06 schrieb Mark Findlater <[email protected]>: > > Is totalViewTime.duration stored as a String in that format? Cypher will not > be able to do what you want. Could you store the duration in a single unit, > say seconds? If you could then you could use MATCH > (totalViewTime:TotalViewTime) RETURN SUM(totalViewTime.duration); > > M > >> On Tuesday, 21 October 2014 06:33:26 UTC+1, Sukaant Chaudhary wrote: >> Hi, >> How to get the sum of duration in (hh:mm:ss) as String >> >> MATCH (totalViewTime:TotalViewTime) RETURN collect(totalViewTime.duration); >> >> >> +---------------------------------------------+ >> | collect(totalViewTime.duration) | >> +---------------------------------------------+ >> | ["02:10:00","00:01:27"] | Expected result is 02:10:00 + >> 00:01:27 = 02:11:27 >> +---------------------------------------------+ >> -Sukaant Chaudhary >> > > -- > You received this message because you are subscribed to the Google Groups > "Neo4j" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups "Neo4j" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
