Skip to content
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

ESQL: Allow multiple columns to refer to the same channel/block #100299

Closed
costin opened this issue Oct 4, 2023 · 4 comments
Closed

ESQL: Allow multiple columns to refer to the same channel/block #100299

costin opened this issue Oct 4, 2023 · 4 comments
Labels
:Analytics/ES|QL AKA ESQL >enhancement Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo)

Comments

@costin
Copy link
Member

costin commented Oct 4, 2023

Description

The layout builder does not allow for a channel to be associated with multiple attributes.
While this is possible, for implementation reasons, this did not trigger the issue.
Consider row a = 1| eval x = a, y = a
There's only one block a yet due to the way eval works, each attribute ends up creating a new channel which is backed by the same block (which has its own set of issue when a page is closed since the block cannot just be closed as it is being used in multiple places - see #100001).

Due to #100174, the issue is made more obvious since the eval x = a are converted into projections which do NOT copy the block but instead just point the new attribute to the same channel.
So row a = 1 | eval x = a, y = a becomes row a = 1 | project a, a as x, a as y where 3 different attributes refer to the same channel (0).
This is a much better representation of the situation and one that aligned with #100001.

Currently this check has been disabled as part of #100238 - I'm raising this issue to properly bubble the behavior up and potentially add more tests to validate the way forward.

@costin costin added >enhancement Team:QL (Deprecated) Meta label for query languages team :Analytics/ES|QL AKA ESQL labels Oct 4, 2023
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-ql (Team:QL)

@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/elasticsearch-esql (:Query Languages/ES|QL)

@wchaparro wchaparro added the Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) label Jan 2, 2024
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-analytics-geo (Team:Analytics)

@elasticsearchmachine elasticsearchmachine removed the Team:QL (Deprecated) Meta label for query languages team label Jan 2, 2024
@costin
Copy link
Member Author

costin commented Jan 30, 2024

This has been fixed as part of the block accounting work.

@costin costin closed this as completed Jan 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Analytics/ES|QL AKA ESQL >enhancement Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo)
Projects
None yet
Development

No branches or pull requests

3 participants