UpdateColumn allows you to update multiple records
(entityOrTable interface{}, columnName string, value interface{}, clauses ...dal.Clause)
| 279 | |
| 280 | // UpdateColumn allows you to update multiple records |
| 281 | func (d *Dalgorm) UpdateColumn(entityOrTable interface{}, columnName string, value interface{}, clauses ...dal.Clause) errors.Error { |
| 282 | d.unwrapDynamic(&entityOrTable, &clauses) |
| 283 | if expr, ok := value.(dal.DalClause); ok { |
| 284 | value = gorm.Expr(expr.Expr, transformParams(expr.Params)...) |
| 285 | } |
| 286 | return d.convertGormError(buildTx(d.db, clauses).Update(columnName, value).Error) |
| 287 | } |
| 288 | |
| 289 | // UpdateColumns allows you to update multiple columns of multiple records |
| 290 | func (d *Dalgorm) UpdateColumns(entityOrTable interface{}, set []dal.DalSet, clauses ...dal.Clause) errors.Error { |
nothing calls this directly
no test coverage detected