go 0 to 3 steps from "player100" over serve,follow bidirect yield distinct id($$) as did,properties($$).age as age,properties($$).name as name | yield count(case $-.age >0 when true then $-.age end) as age, count(case $-.name contains ("T") when true then $-.name end) as name
go 0 to 3 steps from "100" over serve,follow bidirect
yield $$ as did,properties($$).age as age,properties($$).name as name |
group by $-.did yield $-.did as did |
yield
count(case properties($-.did).age >0 when true then properties($-.did).age end) as age,
count(case properties($-.did).name contains ("T") when true then properties($-.did).name end) as name
go 0 to 3 steps from "100" over serve,follow bidirect
yield distinct id($$) as did,properties($$).age as age,properties($$).name as name |
yield
count(case $-.age >0 when true then $-.age end) as age,
count(case $-.name contains ("T") when true then $-.name end) as name
感谢感谢,最终改写成功了,但实测下来就相同语句耗时还不如match,耗时几乎是2倍:
go 0 to 3 steps from “100” over e_user_id,e_device_id,e_finger_id,e_open_id,e_buyer_account bidirect
where (properties(edge).strong_associations==1 OR properties(edge).all_latest_time>=20241214000000)
yield distinct $$ as v1 |
yield COUNT(CASE properties($-.v1).abnormal_107_cancel_list>=1736780487 WHEN true THEN $-.v1 END) as cnt;