Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Neo4J Return column alias (AS) name with space, is it possible?

Using Neo4J 2.1.6 with Cypher.

I was wondering if it's possible to "alias" a query result column with a string containing spaces?

Following code generates error:

enter image description here

error with "..."

MATCH (a)
RETURN a.name AS "My Alias Column Name";

error without ...

MATCH a 
RETURN a.name AS My Alias Column Name;
like image 481
Carlo Luther Avatar asked Dec 14 '22 17:12

Carlo Luther


1 Answers

Spaces are possible, you can alias it using the backticks as follows:

MATCH (a)
RETURN a.age AS `My Alias Age Column Name`;
like image 107
Dave Fauth Avatar answered Mar 16 '23 16:03

Dave Fauth