Open alex-spies opened 1 month ago
Pinging @elastic/es-analytical-engine (Team:Analytics)
https://github.com/elastic/elasticsearch/pull/111253 seems to solve this problem because it makes it so that we never interact with the non-widened data types; e.g. if a field has type short
we'd always treat it as integer
and the reproducer from above works just fine.
Another special case we bumped into: TO_STRING(field)
where field
is float
in one index but double
in another, c.f. https://github.com/elastic/elasticsearch/issues/111910
Union types allow to use differently typed fields from different indices if they have the same name, e.g.
client_ip
with typeip
inindex1
andclient_ip
with typekeyword
inindex2
.However, this seems broken for data types that esql widens, e.g. a field mapped
short
which esql internally represents usinginteger
.Reproducer:
The second query should work, but it returns an error complaining about
a
being ambiguous due to being mapped to different types.