didi / gendry

a golang library for sql builder
Apache License 2.0
1.6k stars 191 forks source link

map[string]interface{} support between ? and ? #146

Closed andotorg closed 10 months ago

andotorg commented 10 months ago

where := map[string]interface{}{ "update_time _between ? and ?": []time.Time{start, end}, }

cond, vals, err := builder.BuildSelect(tableName, where, nil) if nil != err { return nil, err }

not support op write

andotorg commented 10 months ago

Let me support this feature.

andotorg commented 10 months ago

where := map[string]interface{}{ "update_time between": []time.Time{yesterdayMidnight, todayMidnight}, } I see that it's already supported.