- 修复 DbSet/Repository 批量级联保存(ExecuteInserted)失败的问题 #362;

This commit is contained in:
28810
2020-07-05 17:24:50 +08:00
parent d61997d1b2
commit 644de4ac2e
27 changed files with 66 additions and 60 deletions

View File

@ -43,7 +43,7 @@ namespace FreeSql.Odbc.SqlServer
Exception exception = null;
try
{
ret = _orm.Ado.Query<T1>(_connection, _transaction, CommandType.Text, sql, dbParms);
ret = _orm.Ado.Query<T1>(_table.TypeLazy ?? _table.Type, _connection, _transaction, CommandType.Text, sql, dbParms);
}
catch (Exception ex)
{
@ -89,7 +89,7 @@ namespace FreeSql.Odbc.SqlServer
Exception exception = null;
try
{
ret = await _orm.Ado.QueryAsync<T1>(_connection, _transaction, CommandType.Text, sql, dbParms);
ret = await _orm.Ado.QueryAsync<T1>(_table.TypeLazy ?? _table.Type, _connection, _transaction, CommandType.Text, sql, dbParms);
}
catch (Exception ex)
{

View File

@ -87,7 +87,7 @@ namespace FreeSql.Odbc.SqlServer
Exception exception = null;
try
{
ret = _orm.Ado.Query<T1>(_connection, _transaction, CommandType.Text, sql, _params);
ret = _orm.Ado.Query<T1>(_table.TypeLazy ?? _table.Type, _connection, _transaction, CommandType.Text, sql, _params);
}
catch (Exception ex)
{
@ -171,7 +171,7 @@ namespace FreeSql.Odbc.SqlServer
Exception exception = null;
try
{
ret = await _orm.Ado.QueryAsync<T1>(_connection, _transaction, CommandType.Text, sql, _params);
ret = await _orm.Ado.QueryAsync<T1>(_table.TypeLazy ?? _table.Type, _connection, _transaction, CommandType.Text, sql, _params);
}
catch (Exception ex)
{

View File

@ -49,7 +49,7 @@ namespace FreeSql.Odbc.SqlServer
Exception exception = null;
try
{
ret = _orm.Ado.Query<T1>(_connection, _transaction, CommandType.Text, sql, dbParms);
ret = _orm.Ado.Query<T1>(_table.TypeLazy ?? _table.Type, _connection, _transaction, CommandType.Text, sql, dbParms);
ValidateVersionAndThrow(ret.Count);
}
catch (Exception ex)
@ -133,7 +133,7 @@ namespace FreeSql.Odbc.SqlServer
Exception exception = null;
try
{
ret = await _orm.Ado.QueryAsync<T1>(_connection, _transaction, CommandType.Text, sql, dbParms);
ret = await _orm.Ado.QueryAsync<T1>(_table.TypeLazy ?? _table.Type, _connection, _transaction, CommandType.Text, sql, dbParms);
ValidateVersionAndThrow(ret.Count);
}
catch (Exception ex)