Unique constraint??

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Unique constraint??

skavanagh
CONTENTS DELETED
The author has deleted this message.
Reply | Threaded
Open this post in threaded view
|

Re: Unique constraint??

bserdar
We are using unique indexes instead of unique constraints.

On Mon, Aug 18, 2014 at 4:57 PM, skavanagh [via lightblue-dev]
<[hidden email]> wrote:

> I was doing some quick research on how to do it
>
> And I came across this post.
>
> http://stackoverflow.com/a/1933616
>
> So if its a viable feature, maybe you could create a "pointer" document when
> a field has "unique":"true" constraint defined in the schema.  And I guess
> in 'Step 2' you could always delete your existing pointer documents first.
>
> Maybe relations could be handled behind the scenes like that too.  That way
> you could pull back child records without having to load the entire parent
> document.
>
> ref-54321: { primary_doc: "user-9876",  secondary_doc: "cart-1234"},
> ref-54322: { primary_doc: "user-9876",  secondary_doc: "cart-1235"}
>
>
> ________________________________
> If you reply to this email, your message will be added to the discussion
> below:
> http://lightblue-dev.1011138.n3.nabble.com/Unique-constraint-tp56.html
> To start a new topic under lightblue-dev, email
> [hidden email]
> To unsubscribe from lightblue-dev, click here.
> NAML