Open
Description
Hello all,
I have this kind of code :
this.session.Query<EventEntity>()
.Where(e => [...])
.Update(c => new { Enabled = true });
which generate the following SQL :
insert into HT_event SELECT evententit0_.Id as Id FROM event evententit0_ WHERE [...]
UPDATE event SET Enabled=? WHERE (Id) IN (select Id from HT_event)
My EventEntity
is a base class (I have inheritance using table per class hierarchy inheritance mapping with mapping by code). I just tried to update a field on the base class, according to a simple where clause and I want to avoid the creation of a temp table.
I found that Hibernate offer a way to modify the BulkIdStrategy
to use an inline clause for example : http://in.relation.to/2017/02/01/non-temporary-table-bulk-id-strategies/
When do you plan to add this feature to NHibernate ? Thanks a lot for your help.