Adding/removing unique constraints

View: New views
3 Messages — Rating Filter:   Alert me  

Adding/removing unique constraints

by Øyvind Harboe :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Does Cayenne have the ability to add/remove unique constraints for
columns?

--
Øyvind Harboe
http://www.zylin.com/zy1000.html
ARM7 ARM9 XScale Cortex
JTAG debugger and flash programmer

Re: Adding/removing unique constraints

by Tore Halset :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On 8. juli. 2008, at 13.20, Øyvind Harboe wrote:

> Does Cayenne have the ability to add/remove unique constraints for
> columns?

"No" or perhaps "Not yet" :) The cayenne does not have the ability to  
store if a column should have a unique index except for the primary  
key. As it is not stored in the model, the merge-stuff does not  
support it either.

I would love to have the ability to store index info in the model.

  - Tore.


Re: Adding/removing unique constraints

by Øyvind Harboe :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Tue, Jul 8, 2008 at 1:28 PM, Tore Halset <halset@...> wrote:

> On 8. juli. 2008, at 13.20, Øyvind Harboe wrote:
>
>> Does Cayenne have the ability to add/remove unique constraints for
>> columns?
>
> "No" or perhaps "Not yet" :) The cayenne does not have the ability to store
> if a column should have a unique index except for the primary key. As it is
> not stored in the model, the merge-stuff does not support it either.
>
> I would love to have the ability to store index info in the model.

We could probably improve performance if we could add indexes, but it
just isn't worth it unless Cayenne can support it.


--
Øyvind Harboe
http://www.zylin.com/zy1000.html
ARM7 ARM9 XScale Cortex
JTAG debugger and flash programmer
LightInTheBox - Buy quality products at wholesale price