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

Cannot use a string containing space as the key of map #2626

Open
Aiee opened this issue Jul 20, 2021 · 0 comments
Open

Cannot use a string containing space as the key of map #2626

Aiee opened this issue Jul 20, 2021 · 0 comments
Labels
type/feature req Type: feature request

Comments

@Aiee
Copy link
Contributor

Aiee commented Jul 20, 2021

The result is as expected when the key is a single word:

(root@nebula) [nba]> match (v:player) where v.name in {Nobody: 666} return v
+--------------------------------------------+
| v                                          |
+--------------------------------------------+
| ("Nobody" :player{age: 0, name: "Nobody"}) |
+--------------------------------------------+
Got 1 rows (time spent 14177/14658 us)

It fails when using a string containing spaces as the key:

(root@nebula) [nba]> match (v:player) where v.name in ["Tim Duncan"] return v
+-------------------------------------------------------------------------------------------------------------+
| v                                                                                                           |
+-------------------------------------------------------------------------------------------------------------+
| ("Tim Duncan" :bachelor{name: "Tim Duncan", speciality: "psychology"} :player{age: 42, name: "Tim Duncan"}) |
+-------------------------------------------------------------------------------------------------------------+
Got 1 rows (time spent 14180/14591 us)


(root@nebula) [nba]> match (v:player) where v.name in {Tim Duncan: 666} return v
[ERROR (-1004)]: SyntaxError: syntax error near `Duncan'

(root@nebula) [nba]> match (v:player) where v.name in {"Tim Duncan": 666} return v
[ERROR (-1004)]: SyntaxError: syntax error near `: 666} r'
@CPWstatic CPWstatic transferred this issue from vesoft-inc/nebula-graph Aug 27, 2021
@CPWstatic CPWstatic added the type/feature req Type: feature request label Aug 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/feature req Type: feature request
Projects
None yet
Development

No branches or pull requests

2 participants