After some thorough investigation, I'm fairly certain it's not possible to
name PKs with NHibernate, so we're unable to support it either.
I'm going to post a question on the main nhusers mailing list to see if
anyone has any ideas, but I've trawled the schema and done some tests and I
can't find a way to do it. You can name all the other constraints, just not
the primary key.

I guess it's because the primary key is defined inline in the create table
statement, while all other constraints are done as alter table's.

On Tue, Feb 17, 2009 at 10:16 AM, James Gregory <[email protected]>wrote:

> Yeah, no support for this yet.
>
>
> On Tue, Feb 17, 2009 at 9:43 AM, Paul Batum <[email protected]> wrote:
>
>> Ahh, I don't think we have support in for this one yet.
>>
>>
>> On Tue, Feb 17, 2009 at 6:48 PM, Guido Ziliotti <[email protected]
>> > wrote:
>>
>>> Not really, actually I am looking for
>>> Id(x=>x.Id).WithPrimaryKeyName("PK_CLASS");
>>>
>>> I admit I am not sure this can be done since basically I started from
>>> scratch with FluentNhibernate.
>>> By the way I think I'd never started NHibernate without
>>> FluentNhibernate.
>>> Though I think there are some corners where hbm knowledge might still be
>>> necessary, still
>>> I am much happier with FluentNhibernate :D
>>>
>>>
>>> On Tue, Feb 17, 2009 at 4:36 AM, Paul Batum <[email protected]>wrote:
>>>
>>>> I believe you are looking for WithForeignKeyConstraintName().
>>>>
>>>> Paul Batum
>>>>
>>>> On Tue, Feb 17, 2009 at 3:28 AM, Guido Ziliotti <
>>>> [email protected]> wrote:
>>>>
>>>>> Is there a way to control the Primary Name? I mean the Constraint Name
>>>>> not the column?
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>
>>>
>>>
>>
>> >>
>>
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Fluent NHibernate" 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/fluent-nhibernate?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to