mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2026-01-23 13:21:59 +08:00
Update dm
This commit is contained in:
@@ -462,7 +462,7 @@ namespace SqlSugar
|
||||
//string primaryKeyInfo = null;
|
||||
if (columns.Any(it => it.IsPrimarykey) && isCreatePrimaryKey)
|
||||
{
|
||||
sql= sql.TrimEnd(')')+ string.Format(", Primary key({0})", string.Join(",", columns.Where(it => it.IsPrimarykey).Select(it => this.SqlBuilder.GetTranslationColumnName(it.DbColumnName.ToLower()))));
|
||||
sql= sql.TrimEnd(')')+ string.Format(", Primary key({0})", string.Join(",", columns.Where(it => it.IsPrimarykey).Select(it => this.SqlBuilder.GetTranslationColumnName(it.DbColumnName.ToUpper(IsUppper)))));
|
||||
sql = sql + ")";
|
||||
}
|
||||
//sql = sql.Replace("$PrimaryKey", primaryKeyInfo);
|
||||
|
||||
@@ -47,7 +47,7 @@ namespace SqlSugar
|
||||
}
|
||||
else
|
||||
{
|
||||
return this.Context.CurrentConnectionConfig.MoreSettings.IsAutoToUpper == true;
|
||||
return this.SugarContext?.Context?.Context?.CurrentConnectionConfig?.MoreSettings.IsAutoToUpper == true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,9 +37,22 @@ namespace SqlSugar
|
||||
|
||||
private string GetOracleUpdateColums(int i, DbColumnInfo m)
|
||||
{
|
||||
return string.Format("\"{0}\"={1}", m.DbColumnName.ToUpper(), FormatValue(i, m.DbColumnName, m.Value));
|
||||
return string.Format("\"{0}\"={1}", m.DbColumnName.ToUpper(IsUppper), FormatValue(i, m.DbColumnName, m.Value));
|
||||
}
|
||||
public bool IsUppper
|
||||
{
|
||||
get
|
||||
{
|
||||
if (this.Context.CurrentConnectionConfig.MoreSettings == null)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return this.Context.CurrentConnectionConfig.MoreSettings.IsAutoToUpper == true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public object FormatValue(int i, string name, object value)
|
||||
{
|
||||
if (value == null)
|
||||
|
||||
Reference in New Issue
Block a user