Is there a way in Fluent NHibernate (or possibly NHibernate in general) to tell it to generate the primary keys differently? It creates the column name for the key fine, but the index/cons开发者_开发知识库traint gets weird generated names like:
PK__Address__3214EC2725332734
PK__CreditCa__3214EC2756CA82C8
etc.
I can use straight SQL to rename them but I'd rather not.
This is a similar question to this:
Fluent NHibernate primary key constraint naming conventions
It doesn't seem possible to do it because NHibernate itself doesn't support it.
(I was irked to find out).
You should be able to name all constraints thus:
http://marcinobel.com/index.php/fluent-nhibernate-conventions-examples/
Hope this helps, I checked with some colleagues...
精彩评论