dal/pkg/builder/convert_conflict.go
Anton Nesterov 43dd4e9234
[ref] name things what they are
Signed-off-by: Anton Nesterov <anton@demiurg.io>
2024-08-11 21:49:49 +02:00

14 lines
249 B
Go

package builder
import (
"fmt"
"strings"
utils "l12.xyz/dal/utils"
)
func convertConflict(ctx Dialect, fields ...string) string {
keys := utils.Map(fields, ctx.GetColumnName)
return fmt.Sprintf("ON CONFLICT (%s)", strings.Join(keys, ","))
}