Skip to content
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

Question: How do I pass parameters to a cypher query? #133

Open
sam-jay opened this issue Dec 19, 2016 · 3 comments
Open

Question: How do I pass parameters to a cypher query? #133

sam-jay opened this issue Dec 19, 2016 · 3 comments

Comments

@sam-jay
Copy link

sam-jay commented Dec 19, 2016

Couldn't find this info in the docs

@versae
Copy link
Owner

versae commented Dec 20, 2016

Recommended way is by using the Neo4j builtin parameter passing:

q = """match n-[r:`{rel}`]-() return n, n.name, r"""
params = {
    "rel": rel_type,
}
results = self.gdb.query(q, params=params,
                            returns=(client.Node, str, client.Relationship))

@franekp
Copy link

franekp commented Oct 17, 2017

This is a bug in documentation, please document the params argument of GraphDatabase.query().

@versae
Copy link
Owner

versae commented Oct 17, 2017

You are absolutely right, @franekp. Unfortunately, I don't have the time to maintain the library anymore. Any help or PR's are welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants