-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
unable to form bulk upsert query #722
Comments
@lenonqing you can call bulk upset with q := "INSERT INTO role(type,value) VALUES (:type, :value)"
pp := []map[string]interface{}{
{"type": "type1", "value": "val1"},
{"type": "type2", "value": "val2"},
{"type": "type3", "value": "val3"},
}
res, err := db.NamedExec(q, pp) |
it'd be nice to fix this. if you put anything after the |
Any update on this? |
I think version >= 1.3.4 should already fixed this |
yes, version >= 1.3.4 is ok. |
I can confirm, this works on v1.3.5! Maybe close this issue? |
I got the same problem with 1.3.5 version. |
same problem on |
in v 1.3.3
got
sql: expected 5 arguments, got 10
error.The text was updated successfully, but these errors were encountered: