Skip to content

Add remaining 6 sets of SQL tests in quidem#17583

Merged
cryptoe merged 1 commit intoapache:masterfrom
weishiuntsai:qa_test_sql2
Dec 19, 2024
Merged

Add remaining 6 sets of SQL tests in quidem#17583
cryptoe merged 1 commit intoapache:masterfrom
weishiuntsai:qa_test_sql2

Conversation

@weishiuntsai
Copy link
Contributor

This is the 2nd PR as the follow-up of the PR #17548. It migrates the remaining 6 sets of SQL tests to quidem. These 6 sets cover aggregation, array, json, mv, reduction, and other scalar functions.

These tests use the existing kttm dataset. They aim to exercise SQL queries in a more comprehensive way:

Aggregation functions:

  • Each aggregation function is exercised in 1 query shape:
    group by query
  • Each query covers all operators in the predicates of the having clause.
  • All queries are designed to return 7 rows.

Scalar functions:

  • Each scalar function is exercised in 3 different query shapes:
    simple query
    subquery
    group by query
  • Each query covers all operators in the predicates of the where clause.
  • All queries are select count(*) queries. They are designed to all return the same result for easy maintenance and debugging.

This PR has:

  • been self-reviewed.
  • added documentation for new or modified features or behaviors.
  • a release note entry in the PR description.
  • added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
  • added or updated version, license, or notice information in licenses.yaml
  • added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
  • added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
  • added integration tests.
  • been tested in a test Druid cluster.

This is the 2nd part of the PR apache#17548. It migrates the remaining 6 sets of SQL tests to quidem.  These 6 sets cover aggregation, array, json, mv, reduction, and other scalar functions.

These tests use the existing kttm dataset.  They aim to exercise SQL queries in a more comprehensive way:

Aggregation functions:
Each aggregation function is exercised in 1 query shape:
group by query
Each query covers all operators in the predicates of the having clause.
All queries are designed to return 7 rows.
Scalar functions:
Each scalar function is exercised in 3 different query shapes:
simple query
subquery
group by query
Each query covers all operators in the predicates of the where clause.
All queries are select count(*) queries.  They are designed to all return the same result for easy maintenance and debugging.

Update array and mv tests to use the language column

This PR updates the array and the mv tests to use the MV column "language" instead of constructing the data in the queries.
Copy link
Contributor

@cryptoe cryptoe left a comment

Choose a reason for hiding this comment

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

Thanks @weishiuntsai for adding these much needed tests.

@cryptoe cryptoe merged commit 78ce97a into apache:master Dec 19, 2024
@adarshsanjeev adarshsanjeev added this to the 32.0.0 milestone Jan 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants