Skip to content

ESQL: unexpected Unknown column [@timestamp] when using the metrics-only rate aggregation function #124314

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

Open
astefan opened this issue Mar 7, 2025 · 3 comments
Assignees
Labels
:Analytics/ES|QL AKA ESQL >bug Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo)

Comments

@astefan
Copy link
Contributor

astefan commented Mar 7, 2025

Description

from employees | sort rate(languages)

results in

                "reason": "Found 1 problem\nline 1:23: Unknown column [@timestamp]",
                "stack_trace": "org.elasticsearch.xpack.esql.VerificationException: Found 1 problem
line 1:23: Unknown column [@timestamp]
at org.elasticsearch.xpack.esql.analysis.Analyzer.verify(Analyzer.java:203)
at org.elasticsearch.xpack.esql.analysis.Analyzer.analyze(Analyzer.java:197)

Same goes for from employees | stats rate(languages). All these errors shouldn't have happened, instead an error like "the rate aggregate[rate(languages)] can only be used within the metrics command" should have been thrown.

@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-analytical-engine (Team:Analytics)

@elasticsearchmachine elasticsearchmachine added the Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo) label Mar 7, 2025
@wchaparro
Copy link
Member

@martijnvg ping on this one with rate

@martijnvg
Copy link
Member

@dnhatn I think is caused by the recent changes to TS source command?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Analytics/ES|QL AKA ESQL >bug Team:Analytics Meta label for analytical engine team (ESQL/Aggs/Geo)
Projects
None yet
Development

No branches or pull requests

4 participants