Open lukaseder opened 2 weeks ago
Hi @lukaseder, please add branch-* labels to identify which branch(es) this C-bug affects.
:owl: Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.
Hello, I am Blathers. I am here to help you get the issue triaged.
Hoot - a bug! Though bugs are the bane of my existence, rest assured the wretched thing will get the best of care here.
I was unable to automatically find someone to ping.
If we have not gotten back to your issue within a few business days, you can try the following:
:owl: Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.
Describe the problem
When using the
VALUES
constructor mixing integer and numeric literals, there's an error:To Reproduce
Expected behavior
I'd expect the integer to be widened automatically to
numeric
, just like when it is too large to fit in an integer anyway, e.g. this works:E.g. PostgreSQL handles this
Environment:
Workarounds
Avoid the implicit data types with casts:
Or turn the value into a numeric literal:
Use union instead:
Jira issue: CRDB-42860