the unique-key does create a unique index but, like the primary key,
there seems to be no way to specify a name for it.

<property name="FirstName" type="String">
        <column name="FirstName" not-null="true" length="500"
check="FirstName &lt;&gt; ''" unique-key="UQ_FirstName_LastName"/>
</property>
<property name="LastName" type="String">
        <column name="LastName" not-null="true" length="500" check="LastName
&lt;&gt; ''" unique-key="UQ_FirstName_LastName"/>
</property>

My assumption was that the value of the unique-key attribute would
also be the name of the generated index,
but this results in a unique index on called UQ__MyTableNa__762C88DA

I must be trying do something that is not supported.




On Mar 9, 8:02 am, James Gregory <[email protected]> wrote:
> I believe you're looking for unique-key, not index. As for the primary key,
> I don't think you can set the name of the constraint it generates.
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to