Basically I'm trying to do the same thing as this question but with Fluent NHibernate.
Here is my id generation convention:
public class IdGenerationConvention : IIdConvention
{
public void Apply(IIdentityInstance instance)
{
instance.GeneratedBy.HiLo("1000");
}
}
Now this works great, but all classes end up using the same next_hi
.
create table hibernate_unique_key (
next_hi INTEGER
)
Does anyone know how to specify that each class should use it's own next_hi
?
To clarify, I'd like to end up with something like customer_next_hi
and order_next_hi
, assuming it works based on columns. If it's row based then that's fine too, provided each entity knows which row to use for it's next_hi
value.