Started a support discussion about this:

http://help.neo4j.org/discussions/questions/8-re-neo4j-unique-constaint-on-index

2011/7/14 Mattias Persson <matt...@neotechnology.com>

> Creating a support discussion for this.
>
>
> 2011/7/7 Michael Hunger <michael.hun...@neotechnology.com>
>
>> I'd second that for 1.5
>>
>> Michael
>>
>> Sent from my iBrick4
>>
>>
>> Anfang der weitergeleiteten E‑Mail:
>>
>> *Von:* Aseem Kishore <aseem.kish...@gmail.com>
>> *Datum:* 7. Juli 2011 18:14:59 MESZ
>> *An:* Neo4j user discussions <user@lists.neo4j.org>
>> *Betreff:* *Re: [Neo4j] Unique Constaint on Index*
>> *Antwort an:* Neo4j user discussions <user@lists.neo4j.org>
>>
>> I'll strongly +1 that having a concept of "unique" index values should be
>> built into Neo4j. It's just too common of a requirement.
>>
>> Aseem
>>
>> On Thu, Jul 7, 2011 at 11:48 AM, etc3 <e...@nextideapartners.com> wrote:
>>
>> I'm new to this framework, is there an example that demonstrates removing
>> a
>>
>> non-existent property and how it would be used in this context?
>>
>>
>> Thanks
>>
>>
>> -----Original Message-----
>>
>> From: user-boun...@lists.neo4j.org [mailto:user-boun...@lists.neo4j.org]
>>
>> On
>>
>> Behalf Of Chris Gioran
>>
>> Sent: Thursday, July 07, 2011 11:04 AM
>>
>> To: Neo4j user discussions
>>
>> Subject: Re: [Neo4j] Unique Constaint on Index
>>
>>
>> Hi,
>>
>>
>> the ability to acquire locks cluster-wide exists, albeit in an ad hoc
>>
>> fashion. Grabbing a write lock on the node you want to ensure is uniquely
>>
>> indexed will ensure that the operations are serialized across all cluster
>>
>> members.
>>
>> The most simple way to get that lock currently is the (somewhat hackish
>> but
>>
>> entirely correct) removal of a non-existing property.
>>
>>
>> cheers,
>>
>> CG
>>
>>
>> On Thu, Jul 7, 2011 at 5:53 PM, etc3 <e...@nextideapartners.com> wrote:
>>
>> How do I ensure another request is not performing the same operation
>>
>> on another node in the cluster?
>>
>>
>>
>> -----Original Message-----
>>
>> From: <user-boun...@lists.neo4j.org>user-boun...@lists.neo4j.org
>>
>> [mailto:user-boun...@lists.neo4j.org] On Behalf Of Marko Rodriguez
>>
>> Sent: Thursday, July 07, 2011 10:35 AM
>>
>> To: Neo4j user discussions
>>
>> Subject: Re: [Neo4j] Unique Constaint on Index
>>
>>
>> Hi,
>>
>>
>> We are testing Neo4J and need to support unique emails across all
>>
>> users. Is this possible with the current API?
>>
>>
>> You can add such a constraint when updating the indices:
>>
>>
>> if(index.get('email', address).hasNext()) {
>>
>> throw new RuntimeException("There are two nodes that share the same
>>
>> email address."); } else {
>>
>> index.put('email', address, node);
>>
>> }
>>
>>
>> Marko.
>>
>>
>> http://markorodriguez.com
>>
>> _______________________________________________
>>
>> Neo4j mailing list
>>
>> User@lists.neo4j.org
>>
>> https://lists.neo4j.org/mailman/listinfo/user
>>
>>
>> _______________________________________________
>>
>> Neo4j mailing list
>>
>> User@lists.neo4j.org
>>
>> https://lists.neo4j.org/mailman/listinfo/user
>>
>>
>> _______________________________________________
>>
>> Neo4j mailing list
>>
>> User@lists.neo4j.org
>>
>> https://lists.neo4j.org/mailman/listinfo/user
>>
>>
>> _______________________________________________
>>
>> Neo4j mailing list
>>
>> User@lists.neo4j.org
>>
>> https://lists.neo4j.org/mailman/listinfo/user
>>
>>
>> _______________________________________________
>> Neo4j mailing list
>> User@lists.neo4j.org
>> https://lists.neo4j.org/mailman/listinfo/user
>>
>>
>
>
> --
> Mattias Persson, [matt...@neotechnology.com]
> Hacker, Neo Technology
> www.neotechnology.com
>



-- 
Mattias Persson, [matt...@neotechnology.com]
Hacker, Neo Technology
www.neotechnology.com
_______________________________________________
Neo4j mailing list
User@lists.neo4j.org
https://lists.neo4j.org/mailman/listinfo/user

Reply via email to