|
|
@ -234,10 +234,18 @@ namespace SqlSugar |
|
|
|
{ |
|
|
|
item.IndexName = (this.Context.CurrentConnectionConfig.IndexSuffix+ item.IndexName); |
|
|
|
} |
|
|
|
var database = "{db}"; |
|
|
|
if (item.IndexName!=null&&item.IndexName.Contains(database)) |
|
|
|
if (item.IndexName != null) |
|
|
|
{ |
|
|
|
item.IndexName = item.IndexName.Replace(database, this.Context.Ado.Connection.Database); |
|
|
|
var database = "{db}"; |
|
|
|
if (item.IndexName.Contains(database)) |
|
|
|
{ |
|
|
|
item.IndexName = item.IndexName.Replace(database, this.Context.Ado.Connection.Database); |
|
|
|
} |
|
|
|
var table = "{table}"; |
|
|
|
if (item.IndexName.Contains(table)) |
|
|
|
{ |
|
|
|
item.IndexName = item.IndexName.Replace(table, entityInfo.DbTableName); |
|
|
|
} |
|
|
|
} |
|
|
|
if (!this.Context.DbMaintenance.IsAnyIndex(item.IndexName)) |
|
|
|
{ |
|
|
|