Skip to content

Instantly share code, notes, and snippets.

@jmatsushita
Last active August 29, 2015 14:05
Show Gist options
  • Save jmatsushita/74c5a0bb4587cf4b5489 to your computer and use it in GitHub Desktop.
Save jmatsushita/74c5a0bb4587cf4b5489 to your computer and use it in GitHub Desktop.
//setup
[source,cypher]
----
CREATE
(_1 {name:"asfd asdf"}),
(_2 {name:"Aker Solutions"})
----
//graph
=== Querying without wildcard and with double quotes WORKS
[source,cypher]
----
START n=node:node_auto_index('name:"asfd asdf"')
RETURN n;
----
=== Querying with wildcard without quotes and without space WORKS
[source,cypher]
----
START n=node:node_auto_index('name:asfd*')
RETURN n;
----
=== How do I query with space AND wilcard?
==== Doublequotes and escaped space doesn't work
[source,cypher]
----
START n=node:node_auto_index('name:"asfd\ a*"')
RETURN n;
----
==== Doublequotes and double escaped space doesn't work - (No error but NO RESULTS)
[source,cypher]
----
START n=node:node_auto_index('name:asfd\\ a*')
RETURN n;
----
=== Case?
[source,cypher]
----
START n=node:node_auto_index('name:Asfd')
RETURN n;
----
=== Trying with Aker Solutions
[source,cypher]
----
START n=node:node_auto_index('name:Aker\\ Sol*')
RETURN n;
----
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment