Skip to content

Commit

Permalink
add agg function in with
Browse files Browse the repository at this point in the history
  • Loading branch information
nevermore3 committed Dec 6, 2021
1 parent 217d898 commit f3e8afd
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions tests/tck/features/match/With.feature
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,24 @@ Feature: With clause
RETURN *
"""
Then a SemanticError should be raised at runtime: RETURN * is not allowed when there are no variables in scope
When executing query:
"""
MATCH (:player {name:"Chris Paul"})-[:serve]->(b)
WITH collect(b) as teams
RETURN teams
"""
Then the result should be, in any order, with relax comparison:
| teams |
| [("Rockets" :team{name: "Rockets"}), ("Clippers" :team{name: "Clippers"}), ("Hornets" :team{name: "Hornets"})] |
When executing query:
"""
MATCH (:player {name:"Chris Paul"})-[e:like]->(b)
WITH avg(e.likeness) as avg, max(e.likeness) as max
RETURN avg, max
"""
Then the result should be, in any order, with relax comparison:
| avg | max |
| 78.28571428571429 | 99 |

@skip
Scenario: with match return
Expand Down

0 comments on commit f3e8afd

Please sign in to comment.