I am trying to eagerly fetch collections using selects, but all I am getting is inner joins. What is going on?
Session.CreateCriteria(typeof(Foo))
.SetFetchMode("Bars", FetchMode.Select)
.CreateAlias("Bars", "b")
.SetFetchMode("b.Bazes", FetchMode.Select)
.List();
I have tried changing FetchMode to Eager but that doesn't work - I still get inner joins instead of seperate selects. I'm not sure where it is even getting the inner join from, because nothing in the docs talks about FetchMode causing inner joins. Is it possible to get eager selects?
Update OK I worked out that creating an alias causes an inner join. So I can use .CreateAlias("Bars", "b", JoinType.None), but then the fetching of b.Bazes reverts to lazy loading. Urgh.