Re: How do I use the Modeler to define a non key field as unique?

From: Mike Kienenberger (mkienen..laska.net)
Date: Fri Jul 08 2005 - 15:09:41 EDT

  • Next message: Michael Gentry (Yes, I'm a Contractor): "Re: How do I use the Modeler to define a non key field as unique?"

    Joseph Hannon <jah.volcan..mail.com> wrote:
    > I formerly used Hibernate as my orm framework and have switched over
    > to Cayenne 1.2M4 to try it out. I am running a Fedora Core 3 Linux box
    > for development. I have been working with the modeler tool and gotten
    > some simple schemas and classes to work. I am used to writing my own
    > schemas by hand and would commonly write the following inside a create
    > table script for Oracle:
    >
    > create table PICARD
    > (
    > OID integer primary key,
    > FOO_BAR varchar2(100) not null unique
    > ) ;
    >
    > PICARD.OID is the PK and PICARD.FOO_BAR is just unique. What I don't
    > want is for OID and FOO_BAR to be a composite key. How would I do
    > this using the modeler?

    Just mark OID as a primary key.

    I don't think there's support in the modeler yet for defining unique or
    other forms of indexing.

    -Mike



    This archive was generated by hypermail 2.0.0 : Fri Jul 08 2005 - 15:06:43 EDT