mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-05 17:37:58 +08:00
Update dm
This commit is contained in:
parent
223256f291
commit
f3b69b6ac2
@ -43,6 +43,10 @@ namespace SqlSugar
|
||||
{
|
||||
return "other";
|
||||
}
|
||||
else if (dbTypeName == "sbyte")
|
||||
{
|
||||
return "byte";
|
||||
}
|
||||
else if (dbTypeName == "xml" || dbTypeName == "string")
|
||||
{
|
||||
return "string";
|
||||
|
@ -359,6 +359,10 @@ namespace SqlSugar
|
||||
private List<DbColumnInfo> GetColumnInfosByTableName(string tableName)
|
||||
{
|
||||
string sql = "select * from " + SqlBuilder.GetTranslationTableName(tableName) + " WHERE 1=2 ";
|
||||
if (!this.GetTableInfoList(false).Any(it => it.Name == SqlBuilder.GetTranslationTableName(tableName).TrimStart('\"').TrimEnd('\"')))
|
||||
{
|
||||
sql = "select * from \"" + tableName + "\" WHERE 1=2 ";
|
||||
}
|
||||
var oldIsEnableLog = this.Context.Ado.IsEnableLogEvent;
|
||||
this.Context.Ado.IsEnableLogEvent = false;
|
||||
using(DbDataReader reader = (DbDataReader) this.Context.Ado.GetDataReader(sql))
|
||||
|
Loading…
Reference in New Issue
Block a user