mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-08-23 22:11:36 +08:00
5.0.6.5
This commit is contained in:
parent
ccaf62ba87
commit
d6d96076cb
@ -106,7 +106,10 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
if (sqlParameter.DbType == System.Data.DbType.Guid) {
|
if (sqlParameter.DbType == System.Data.DbType.Guid) {
|
||||||
sqlParameter.DbType = System.Data.DbType.String;
|
sqlParameter.DbType = System.Data.DbType.String;
|
||||||
sqlParameter.Value = sqlParameter.Value.ObjToString();
|
if (sqlParameter.Value != DBNull.Value)
|
||||||
|
{
|
||||||
|
sqlParameter.Value = sqlParameter.Value.ObjToString();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (isVarchar && sqlParameter.DbType == System.Data.DbType.String)
|
if (isVarchar && sqlParameter.DbType == System.Data.DbType.String)
|
||||||
{
|
{
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<package >
|
<package >
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>SqlSugarCore</id>
|
<id>SqlSugarCore</id>
|
||||||
<version>5.0.6.4</version>
|
<version>5.0.6.5</version>
|
||||||
<authors>sunkaixuan</authors>
|
<authors>sunkaixuan</authors>
|
||||||
<owners>果糖大数据科技</owners>
|
<owners>果糖大数据科技</owners>
|
||||||
<licenseUrl>http://www.apache.org/licenses/LICENSE-2.0.html</licenseUrl>
|
<licenseUrl>http://www.apache.org/licenses/LICENSE-2.0.html</licenseUrl>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<package >
|
<package >
|
||||||
<metadata>
|
<metadata>
|
||||||
<id>SqlSugarCoreNoDrive</id>
|
<id>SqlSugarCoreNoDrive</id>
|
||||||
<version>5.0.6.4</version>
|
<version>5.0.6.5</version>
|
||||||
<authors>sunkaixuan</authors>
|
<authors>sunkaixuan</authors>
|
||||||
<owners>Landa</owners>
|
<owners>Landa</owners>
|
||||||
<licenseUrl>http://www.apache.org/licenses/LICENSE-2.0.html</licenseUrl>
|
<licenseUrl>http://www.apache.org/licenses/LICENSE-2.0.html</licenseUrl>
|
||||||
|
@ -3,7 +3,7 @@ using System.Collections.Generic;
|
|||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
using SqlSugar;
|
||||||
namespace OrmTest
|
namespace OrmTest
|
||||||
{
|
{
|
||||||
public partial class NewUnitTest
|
public partial class NewUnitTest
|
||||||
@ -13,6 +13,17 @@ namespace OrmTest
|
|||||||
if (Db.DbMaintenance.IsAnyTable("UnitCodeTest1", false))
|
if (Db.DbMaintenance.IsAnyTable("UnitCodeTest1", false))
|
||||||
Db.DbMaintenance.DropTable("UnitCodeTest1");
|
Db.DbMaintenance.DropTable("UnitCodeTest1");
|
||||||
Db.CodeFirst.InitTables<UnitCodeTest1>();
|
Db.CodeFirst.InitTables<UnitCodeTest1>();
|
||||||
|
Db.CodeFirst.InitTables<Test00111>();
|
||||||
|
Db.DbMaintenance.TruncateTable<Test00111>();
|
||||||
|
Db.Insertable(new Test00111()).ExecuteCommand();
|
||||||
|
var list = Db.Queryable<Test00111>().ToList();
|
||||||
|
}
|
||||||
|
|
||||||
|
public class Test00111
|
||||||
|
{
|
||||||
|
public int id { get; set; }
|
||||||
|
[SugarColumn(ColumnDataType = "guid",IsNullable =true)]
|
||||||
|
public Guid? creater { get; set; }
|
||||||
}
|
}
|
||||||
public class UnitCodeTest1
|
public class UnitCodeTest1
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user