- 修复 Oracle/Sqlite IInsert.ExecuteInserted 方法,返回了被 clear 过后的 _source;

This commit is contained in:
28810 2019-11-29 21:46:53 +08:00
parent 27f053f00b
commit dcd0ef5750
3 changed files with 12 additions and 6 deletions

View File

@ -144,8 +144,9 @@ namespace FreeSql.Odbc.Oracle
var sql = this.ToSql(); var sql = this.ToSql();
if (string.IsNullOrEmpty(sql)) return new List<T1>(); if (string.IsNullOrEmpty(sql)) return new List<T1>();
var ret = _source.ToList();
this.RawExecuteAffrows(); this.RawExecuteAffrows();
return _source; return ret;
} }
#if net40 #if net40
@ -212,8 +213,9 @@ namespace FreeSql.Odbc.Oracle
var sql = this.ToSql(); var sql = this.ToSql();
if (string.IsNullOrEmpty(sql)) return new List<T1>(); if (string.IsNullOrEmpty(sql)) return new List<T1>();
var ret = _source.ToList();
await this.RawExecuteAffrowsAsync(); await this.RawExecuteAffrowsAsync();
return _source; return ret;
} }
#endif #endif
} }

View File

@ -145,8 +145,9 @@ namespace FreeSql.Oracle.Curd
var sql = this.ToSql(); var sql = this.ToSql();
if (string.IsNullOrEmpty(sql)) return new List<T1>(); if (string.IsNullOrEmpty(sql)) return new List<T1>();
var ret = _source.ToList();
this.RawExecuteAffrows(); this.RawExecuteAffrows();
return _source; return ret;
} }
#if net40 #if net40
@ -213,8 +214,9 @@ namespace FreeSql.Oracle.Curd
var sql = this.ToSql(); var sql = this.ToSql();
if (string.IsNullOrEmpty(sql)) return new List<T1>(); if (string.IsNullOrEmpty(sql)) return new List<T1>();
var ret = _source.ToList();
await this.RawExecuteAffrowsAsync(); await this.RawExecuteAffrowsAsync();
return _source; return ret;
} }
#endif #endif
} }

View File

@ -52,8 +52,9 @@ namespace FreeSql.Sqlite.Curd
var sql = this.ToSql(); var sql = this.ToSql();
if (string.IsNullOrEmpty(sql)) return new List<T1>(); if (string.IsNullOrEmpty(sql)) return new List<T1>();
var ret = _source.ToList();
this.RawExecuteAffrows(); this.RawExecuteAffrows();
return _source; return ret;
} }
#if net40 #if net40
@ -93,8 +94,9 @@ namespace FreeSql.Sqlite.Curd
var sql = this.ToSql(); var sql = this.ToSql();
if (string.IsNullOrEmpty(sql)) return new List<T1>(); if (string.IsNullOrEmpty(sql)) return new List<T1>();
var ret = _source.ToList();
await this.RawExecuteAffrowsAsync(); await this.RawExecuteAffrowsAsync();
return _source; return ret;
} }
#endif #endif
} }