The example in https://hibernate.atlassian.net/browse/HHH-15517 has shown that we currently create a multi-table insert plan because the sequence optimizer has an allocation size bigger than 1, although it wouldn’t be necessary because the statement assigns an id already. The improvement is to use the SimpleInsertQueryPlan to avoid creating a temporary table. |