fix: 修复statement GenExistSQL 只有表名,没有RefTable时,未拼接别名Alias的BUG
This commit is contained in:
parent
c3311fae2b
commit
7935b27dd8
|
@ -314,8 +314,6 @@ func (statement *Statement) GenExistSQL(bean ...interface{}) (string, []interfac
|
||||||
return statement.Limit(1).GenGetSQL(b)
|
return statement.Limit(1).GenGetSQL(b)
|
||||||
}
|
}
|
||||||
|
|
||||||
tableName = statement.quote(tableName)
|
|
||||||
|
|
||||||
buf := builder.NewWriter()
|
buf := builder.NewWriter()
|
||||||
if statement.dialect.URI().DBType == schemas.MSSQL {
|
if statement.dialect.URI().DBType == schemas.MSSQL {
|
||||||
if _, err := fmt.Fprintf(buf, "SELECT TOP 1 *"); err != nil {
|
if _, err := fmt.Fprintf(buf, "SELECT TOP 1 *"); err != nil {
|
||||||
|
|
Loading…
Reference in New Issue