Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Fixed interval type null/missing check failure #1011

Merged
merged 3 commits into from
Jan 28, 2021

Conversation

chloe-zh
Copy link
Member

Issue #, if available:
#991

Description of changes:

  • Interval type failed semantic check in aggregations with implicit group by, so added interval type as literal type to be non-aggregation select items to pass the check
  • Handled null and missing value check for interval type
  • Added corresponding tests. Note: didn't add comparison test because missing INTERVAL in JDBC types

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@chloe-zh chloe-zh added the SQL label Jan 26, 2021
@chloe-zh chloe-zh self-assigned this Jan 26, 2021
@codecov
Copy link

codecov bot commented Jan 26, 2021

Codecov Report

Merging #1011 (f31672b) into develop (1101df0) will decrease coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@              Coverage Diff              @@
##             develop    #1011      +/-   ##
=============================================
- Coverage      99.87%   99.87%   -0.01%     
+ Complexity      2406     2403       -3     
=============================================
  Files            234      234              
  Lines           5526     5520       -6     
  Branches         357      357              
=============================================
- Hits            5519     5513       -6     
  Misses             5        5              
  Partials           2        2              
Impacted Files Coverage Δ Complexity Δ
...search/sql/expression/datetime/IntervalClause.java 100.00% <100.00%> (ø) 21.00 <0.00> (ø)
...icsearch/sql/sql/parser/AstAggregationBuilder.java 100.00% <100.00%> (ø) 14.00 <4.00> (-3.00)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1101df0...f31672b. Read the comment docs.

@dai-chen dai-chen added the bug Something isn't working label Jan 26, 2021
Copy link
Member

@dai-chen dai-chen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

Copy link
Contributor

@penghuo penghuo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chloe-zh chloe-zh merged commit 4ec31b0 into opendistro-for-elasticsearch:develop Jan 28, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working SQL
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants