Usability of batch inserts for Map type #1629
Closed
nikita-vanyasin
started this conversation in
Feature requests
Replies: 1 comment
-
The driver uses a lot of reflection to determine and iterate types. With the specific samples you provided, I believe the Go specification on type identity is relevant: https://go.dev/ref/spec#Type_identity Sure we could probably solve this with reflection, but it's a fair performance tradeoff to simply prefer a standard map in this case. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
A minor usability issue report.
The next code
Fails with:
If we explicitly cast to map types, it works fine:
Given that template.KV type is defined as
type KV map[string]string
, I think it should be possible to just pass it as-is to Append without explicit cast.Beta Was this translation helpful? Give feedback.
All reactions