Browse Source

Complex query BUG

pull/6/head
sunkaixuna 3 years ago
parent
commit
72aa41a632
  1. 1
      Src/Asp.NetCore2/SqlSeverTest/SqlSeverTest/UnitTest/UInsert.cs
  2. 2
      Src/Asp.NetCore2/SqlSeverTest/SqlSugar/Abstract/SqlBuilderProvider/QueryBuilder.cs

1
Src/Asp.NetCore2/SqlSeverTest/SqlSeverTest/UnitTest/UInsert.cs

@ -11,6 +11,7 @@ namespace OrmTest
public static void Insert()
{
var db = Db;
db.CodeFirst.InitTables<UinitBlukTable>();
db.DbMaintenance.TruncateTable<UinitBlukTable>();
db.CodeFirst.InitTables<UinitBlukTable>();
db.Insertable(new List<UinitBlukTable>

2
Src/Asp.NetCore2/SqlSeverTest/SqlSugar/Abstract/SqlBuilderProvider/QueryBuilder.cs

@ -256,7 +256,7 @@ namespace SqlSugar
resolveExpress.SqlFuncServices = Context.CurrentConnectionConfig.ConfigureExternalServices == null ? null : Context.CurrentConnectionConfig.ConfigureExternalServices.SqlFuncServices;
};
resolveExpress.Resolve(expression, resolveType);
this.Parameters.AddRange(resolveExpress.Parameters);
this.Parameters.AddRange(resolveExpress.Parameters.Select(it=>new SugarParameter(it.ParameterName, it.Value)));
var result = resolveExpress.Result;
var isSingleTableHasSubquery = IsSingle() && resolveExpress.SingleTableNameSubqueryShortName.HasValue();
if (isSingleTableHasSubquery)

Loading…
Cancel
Save