Reputation: 103517
In my hbm files I did this:
<property name="Title" column="title" type="string" length="100" not-null="true"></property>
I am assuming this will provide for faster data access because it is providing more information i.e. length.
Does fluent provide this behavior?
Upvotes: 0
Views: 403
Reputation: 10851
Yes, Fluent NHibernate lets you do the equivalent mapping
The Fluent NHibernate mapping would look something like this:
Map(x = x.Title)
.ColumnName("title")
.WithLengthOf(100)
.Not.Nullable();
Upvotes: 2