Update unit bug

This commit is contained in:
sunkaixuan
2022-04-12 16:27:23 +08:00
parent 888dd7681e
commit 43fd8fc3a5
4 changed files with 41 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace OrmTest
{
public class UCustom013
{
public static void Init()
{
var db = new SqlSugarScope(new SqlSugar.ConnectionConfig()
{
ConnectionString = Config.ConnectionString,
DbType = DbType.SqlServer,
IsAutoCloseConnection = true
});
db.CodeFirst.InitTables<UnitBoola1>();
db.Queryable<Order>()
.Select(x => new
{
x1 = SqlFunc.Subqueryable<UnitBoola1>().Select(it => it.a)
}).ToList();
}
public class UnitBoola1
{
public bool a { get; set; }
}
}
}