Re: [Neo4j] How can we copy labels from one node to another in one cypher?

2016-02-08 Thread Michael Hunger
Right now that's unfortunately not possible with Cypher.

You will have to match + enumerate manually.

On Thu, Feb 4, 2016 at 3:23 AM, zhang han <289211...@qq.com> wrote:

> The question is just as the title, and the cypher statement is just like
> the follow:
> Match (n: test) CREATE (copy : LABELS(n)) set copy = n
> Its purpose is to create a node with the same properties and same labels
> as the other node, but it doesn't work now because we can't use a
> expression like "LABELS(n)" to set lobel to a node.
> How can I make it work?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Neo4j" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to neo4j+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to neo4j+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Neo4j] How can we copy labels from one node to another in one cypher?

2016-02-08 Thread zhang han
The question is just as the title, and the cypher statement is just like 
the follow:
Match (n: test) CREATE (copy : LABELS(n)) set copy = n
Its purpose is to create a node with the same properties and same labels as 
the other node, but it doesn't work now because we can't use a expression 
like "LABELS(n)" to set lobel to a node. 
How can I make it work?

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to neo4j+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Neo4j] How can we copy labels from one node to another in one cypher?

2016-02-08 Thread Michael Hunger
I look into providing a procedure / extension for that.

On Tue, Feb 9, 2016 at 7:01 AM, Michael Hunger <
michael.hun...@neotechnology.com> wrote:

> Right now that's unfortunately not possible with Cypher.
>
> You will have to match + enumerate manually.
>
> On Thu, Feb 4, 2016 at 3:23 AM, zhang han <289211...@qq.com> wrote:
>
>> The question is just as the title, and the cypher statement is just like
>> the follow:
>> Match (n: test) CREATE (copy : LABELS(n)) set copy = n
>> Its purpose is to create a node with the same properties and same labels
>> as the other node, but it doesn't work now because we can't use a
>> expression like "LABELS(n)" to set lobel to a node.
>> How can I make it work?
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Neo4j" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to neo4j+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Neo4j" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to neo4j+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.