Update Queryable.ToSqlString()

This commit is contained in:
sunkaixuan 2022-09-01 14:02:44 +08:00
parent 9c6e10e57e
commit acb1bc3cb5

View File

@ -823,6 +823,10 @@ namespace SqlSugar
{
result = result.Replace(item.ParameterName, item.Value.ObjToString());
}
else if (item.Value is DateTime)
{
result = result.Replace(item.ParameterName, "'"+item.Value.ObjToDate().ToString("yyyy-MM-dd HH:mm:ss.fff")+"'");
}
else if (item.Value is byte[])
{
result = result.Replace(item.ParameterName, "0x" + BitConverter.ToString((byte[])item.Value));