-
Notifications
You must be signed in to change notification settings - Fork 936
Description
Using this (simplified) code (running with Dotnet Core):
public void Execute(ISessionFactory factory)
{
using(var session = factory.OpenSession())
using(var tx = session.BeginTransaction())
{
// Total row number is not written to log
var future = session.CreateQuery("select Id As Id from Post")
.SetResultTransformer(Transformers.AliasToBean<PostId>())
.Future<PostId>();
future.ToList();
// This is ok - total row number is written to log
// session.CreateCriteria<Blog>().List<Blog>();
tx.Commit();
}
}
public class PostId
{
public int Id { get; set; }
}
-
With NHibernate 5.2.6, The total 'row count' log message is Not written to the log
I only receive the following:
"result row: "
(from NHibernate.Loader.Loader:)
with No row count information! -
With the previous Nhibernate 5.1.3, the total was written and we had (for example):
"result set row: 1"
(from NHibernate.Impl.MultiQueryImpl)AND we also got:
"done processing result set (10 rows)"
(from NHibernate.Impl.MultiQueryImpl) -
I see that MultiQueryImpl is obsolete
[Obsolete("Use Multi.QueryBatch instead, obtainable with ISession.CreateQueryBatch.")] -
BUT, for example, when the following code snippet is run (with NHibernate 5.2.6):
session.CreateCriteria<Blog>().List<Blog>();
we do get the expected msg in the log from Loader.cs
"done processing result set (5 rows)"
(from NHibernate.Loader.Loader:) -
So, can you please provide this missing functionality?