File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -366,7 +366,7 @@ func (q *Query) AppendColumn(columns ...string) *Query {
366
366
t := q .tableModel .Table ()
367
367
if q .columns == nil {
368
368
for _ , f := range t .Fields {
369
- q .columns = append (q .columns , fieldAppender { fmt . Sprintf ( "%s.%s " , t .Alias , f .SQLName )} )
369
+ q .columns = append (q .columns , SafeQuery ( "?.? " , t .Alias , f .Column ) )
370
370
}
371
371
}
372
372
return q .Column (columns ... )
@@ -378,7 +378,7 @@ func (q *Query) AppendColumnExpr(expr string, params ...interface{}) *Query {
378
378
t := q .tableModel .Table ()
379
379
if q .columns == nil {
380
380
for _ , f := range t .Fields {
381
- q .columns = append (q .columns , fieldAppender { fmt . Sprintf ( "%s.%s " , t .Alias , f .SQLName )} )
381
+ q .columns = append (q .columns , SafeQuery ( "?.? " , t .Alias , f .Column ) )
382
382
}
383
383
}
384
384
return q .ColumnExpr (expr , params ... )
You can’t perform that action at this time.
0 commit comments