-
Notifications
You must be signed in to change notification settings - Fork 154
count(): Float cannot represent non numeric value #237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @DomVinyard. Our translation is initialized at the root, whereas your type Nested {
count: Float
}
type Query {
test: Nested
@cypher(
statement: """
MATCH (n)
WITH count(n) as count
RETURN { count: count }
"""
)
} Then you can query: {
test {
count
}
} and get a response like:
|
And if it's deeply nested?
? |
Could you expend on that? Do you mean the first example is not supposed to work? type Movie {
movieId: ID!
title: String
description: String
year: Int
actors(limit: Int = 10): [Actor]
@relationship(type: "ACTED_IN", direction: IN)
similarMovies(limit: Int = 10): [Movie]
@cypher(
statement: """
MATCH (this)<-[:ACTED_IN]-(:Actor)-[:ACTED_IN]->(rec:Movie)
WITH rec, COUNT(*) AS score ORDER BY score DESC
RETURN rec LIMIT $limit
"""
)
} What's the difference here between |
After much back and forth of thinking we had fixed this bug, it should finally be fully fixed by #297. 🤞 Apologies it took a while to get to this stage, it was a tricky bug to find but then very clear once we had found it! |
A custom cypher query which returns a count is not resolving correctly:
As seen: neo4j/neo4j-javascript-driver#225
If I try to return this as a scalar
Our current workaround is a customer resolver
The text was updated successfully, but these errors were encountered: