mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-07-15 14:04:44 +08:00
Update sqlserver remark
This commit is contained in:
parent
fa2b6f20b5
commit
38598bce9c
@ -360,6 +360,10 @@ namespace SqlSugar
|
||||
var schema = tableName.Split('.').First();
|
||||
tableName = tableName.Split('.').Last();
|
||||
var temp = this.DeleteColumnRemarkSql.Replace(",dbo,", $",{schema},");
|
||||
if (!schema.EqualCase("dbo"))
|
||||
{
|
||||
temp = temp.Replace("N'user'", $"N'schema'");
|
||||
}
|
||||
string sql = string.Format(temp, columnName, tableName);
|
||||
this.Context.Ado.ExecuteCommand(sql);
|
||||
return true;
|
||||
@ -377,6 +381,10 @@ namespace SqlSugar
|
||||
var schema = tableName.Split('.').First();
|
||||
tableName = tableName.Split('.').Last();
|
||||
var temp = this.AddColumnRemarkSql.Replace("N'dbo'", $"N'{schema}'");
|
||||
if (!schema.EqualCase("dbo"))
|
||||
{
|
||||
temp= temp.Replace("N'user'", $"N'schema'");
|
||||
}
|
||||
string sql = string.Format(temp, columnName, tableName, description);
|
||||
this.Context.Ado.ExecuteCommand(sql);
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user