Skip to content

Commit

Permalink
Feature #72: Support aggregate and analytics functions (#122)
Browse files Browse the repository at this point in the history
* Increment minor version, add change notes

* Update changelog version to 4.5.0

* Rename constant to match naming conventions

* Add AnalyticFunction with keyword support

* Remove duplicate code

* Document creating analytic functions

* Initial support for OVER clause

* Add order by to over clause

* Move analytic & aggregate functions to new enum

* Implement units and exclusion for over clause

* Apply suggestions from code review

Co-authored-by: jakobbraun <[email protected]>

* Remove WindowClause

This will be implemented in #128

* Update dependencies in changelog

* Add javadoc

* Add unit tests

* Update user guide

* Update list of aggregate & analytic functions

* Format function names and add links to the documentation

* Update release date

* Apply suggestions from code review

Co-authored-by: jakobbraun <[email protected]>

* Implement review findings

Co-authored-by: jakobbraun <[email protected]>
  • Loading branch information
kaklakariada and jakobbraun authored Sep 30, 2021
1 parent 7c74ae0 commit fd2ca2a
Show file tree
Hide file tree
Showing 22 changed files with 1,584 additions and 346 deletions.
131 changes: 69 additions & 62 deletions dependencies.md
Original file line number Diff line number Diff line change
@@ -1,73 +1,80 @@
<!-- @formatter:off -->
# Dependencies

## Compile Dependencies

| Dependency | License |
| ------------------------- | -------- |
| [error-reporting-java][0] | [MIT][1] |

## Test Dependencies

| Dependency | License |
| ------------------------------- | -------------------------------- |
| [JUnit Jupiter (Aggregator)][0] | [Eclipse Public License v2.0][1] |
| [Hamcrest All][2] | [New BSD License][3] |
| [mockito-core][4] | [The MIT License][5] |
| [mockito-junit-jupiter][4] | [The MIT License][5] |
| [EqualsVerifier][8] | [Apache License, Version 2.0][9] |
| Dependency | License |
| ------------------------------- | --------------------------------- |
| [JUnit Jupiter (Aggregator)][2] | [Eclipse Public License v2.0][3] |
| [Hamcrest All][4] | [New BSD License][5] |
| [mockito-core][6] | [The MIT License][7] |
| [mockito-junit-jupiter][6] | [The MIT License][7] |
| [EqualsVerifier][10] | [Apache License, Version 2.0][11] |

## Plugin Dependencies

| Dependency | License |
| ------------------------------------------------------- | ------------------------------------- |
| [Apache Maven Compiler Plugin][10] | [Apache License, Version 2.0][11] |
| [JaCoCo :: Maven Plugin][12] | [Eclipse Public License 2.0][13] |
| [Maven Surefire Plugin][14] | [Apache License, Version 2.0][11] |
| [Apache Maven Source Plugin][16] | [Apache License, Version 2.0][11] |
| [Apache Maven Javadoc Plugin][18] | [Apache License, Version 2.0][11] |
| [Apache Maven GPG Plugin][20] | [Apache License, Version 2.0][11] |
| [OpenFastTrace Maven Plugin][22] | [GNU General Public License v3.0][23] |
| [org.sonatype.ossindex.maven:ossindex-maven-plugin][24] | [ASL2][9] |
| [Versions Maven Plugin][26] | [Apache License, Version 2.0][11] |
| [Apache Maven Enforcer Plugin][28] | [Apache License, Version 2.0][11] |
| [Nexus Staging Maven Plugin][30] | [Eclipse Public License][31] |
| [Project keeper maven plugin][32] | [MIT][33] |
| [Maven Failsafe Plugin][34] | [Apache License, Version 2.0][11] |
| [Apache Maven Deploy Plugin][36] | [Apache License, Version 2.0][9] |
| [error-code-crawler-maven-plugin][38] | [MIT][33] |
| [Reproducible Build Maven Plugin][40] | [Apache 2.0][9] |
| [Apache Maven Clean Plugin][42] | [Apache License, Version 2.0][11] |
| [Apache Maven Resources Plugin][44] | [Apache License, Version 2.0][11] |
| [Apache Maven JAR Plugin][46] | [Apache License, Version 2.0][11] |
| [Apache Maven Install Plugin][48] | [Apache License, Version 2.0][9] |
| [Apache Maven Site Plugin][50] | [Apache License, Version 2.0][11] |
| [Apache Maven Compiler Plugin][12] | [Apache License, Version 2.0][13] |
| [JaCoCo :: Maven Plugin][14] | [Eclipse Public License 2.0][15] |
| [Maven Surefire Plugin][16] | [Apache License, Version 2.0][13] |
| [Apache Maven Source Plugin][18] | [Apache License, Version 2.0][13] |
| [Apache Maven Javadoc Plugin][20] | [Apache License, Version 2.0][13] |
| [Apache Maven GPG Plugin][22] | [Apache License, Version 2.0][13] |
| [OpenFastTrace Maven Plugin][24] | [GNU General Public License v3.0][25] |
| [org.sonatype.ossindex.maven:ossindex-maven-plugin][26] | [ASL2][11] |
| [Versions Maven Plugin][28] | [Apache License, Version 2.0][13] |
| [Apache Maven Enforcer Plugin][30] | [Apache License, Version 2.0][13] |
| [Nexus Staging Maven Plugin][32] | [Eclipse Public License][33] |
| [Project keeper maven plugin][34] | [MIT][1] |
| [Maven Failsafe Plugin][36] | [Apache License, Version 2.0][13] |
| [Apache Maven Deploy Plugin][38] | [Apache License, Version 2.0][11] |
| [error-code-crawler-maven-plugin][40] | [MIT][1] |
| [Reproducible Build Maven Plugin][42] | [Apache 2.0][11] |
| [Apache Maven Clean Plugin][44] | [Apache License, Version 2.0][13] |
| [Apache Maven Resources Plugin][46] | [Apache License, Version 2.0][13] |
| [Apache Maven JAR Plugin][48] | [Apache License, Version 2.0][13] |
| [Apache Maven Install Plugin][50] | [Apache License, Version 2.0][11] |
| [Apache Maven Site Plugin][52] | [Apache License, Version 2.0][13] |

[32]: https://github.com/exasol/project-keeper-maven-plugin
[2]: https://github.com/hamcrest/JavaHamcrest
[9]: http://www.apache.org/licenses/LICENSE-2.0.txt
[14]: https://maven.apache.org/surefire/maven-surefire-plugin/
[30]: http://www.sonatype.com/public-parent/nexus-maven-plugins/nexus-staging/nexus-staging-maven-plugin/
[4]: https://github.com/mockito/mockito
[33]: https://opensource.org/licenses/MIT
[34]: https://maven.apache.org/surefire/maven-failsafe-plugin/
[26]: http://www.mojohaus.org/versions-maven-plugin/
[10]: https://maven.apache.org/plugins/maven-compiler-plugin/
[44]: https://maven.apache.org/plugins/maven-resources-plugin/
[22]: https://github.com/itsallcode/openfasttrace-maven-plugin
[42]: https://maven.apache.org/plugins/maven-clean-plugin/
[13]: https://www.eclipse.org/legal/epl-2.0/
[31]: http://www.eclipse.org/legal/epl-v10.html
[12]: https://www.jacoco.org/jacoco/trunk/doc/maven.html
[5]: https://github.com/mockito/mockito/blob/main/LICENSE
[40]: http://zlika.github.io/reproducible-build-maven-plugin
[50]: https://maven.apache.org/plugins/maven-site-plugin/
[23]: https://www.gnu.org/licenses/gpl-3.0.html
[11]: https://www.apache.org/licenses/LICENSE-2.0.txt
[28]: https://maven.apache.org/enforcer/maven-enforcer-plugin/
[1]: https://www.eclipse.org/legal/epl-v20.html
[3]: http://www.opensource.org/licenses/bsd-license.php
[48]: http://maven.apache.org/plugins/maven-install-plugin/
[0]: https://junit.org/junit5/
[24]: https://sonatype.github.io/ossindex-maven/maven-plugin/
[20]: https://maven.apache.org/plugins/maven-gpg-plugin/
[8]: http://www.jqno.nl/equalsverifier
[16]: https://maven.apache.org/plugins/maven-source-plugin/
[36]: http://maven.apache.org/plugins/maven-deploy-plugin/
[18]: https://maven.apache.org/plugins/maven-javadoc-plugin/
[38]: https://github.com/exasol/error-code-crawler-maven-plugin
[46]: https://maven.apache.org/plugins/maven-jar-plugin/
[34]: https://github.com/exasol/project-keeper-maven-plugin
[0]: https://github.com/exasol/error-reporting-java
[4]: https://github.com/hamcrest/JavaHamcrest
[11]: http://www.apache.org/licenses/LICENSE-2.0.txt
[16]: https://maven.apache.org/surefire/maven-surefire-plugin/
[32]: http://www.sonatype.com/public-parent/nexus-maven-plugins/nexus-staging/nexus-staging-maven-plugin/
[1]: https://opensource.org/licenses/MIT
[6]: https://github.com/mockito/mockito
[36]: https://maven.apache.org/surefire/maven-failsafe-plugin/
[28]: http://www.mojohaus.org/versions-maven-plugin/
[12]: https://maven.apache.org/plugins/maven-compiler-plugin/
[46]: https://maven.apache.org/plugins/maven-resources-plugin/
[24]: https://github.com/itsallcode/openfasttrace-maven-plugin
[44]: https://maven.apache.org/plugins/maven-clean-plugin/
[15]: https://www.eclipse.org/legal/epl-2.0/
[33]: http://www.eclipse.org/legal/epl-v10.html
[14]: https://www.jacoco.org/jacoco/trunk/doc/maven.html
[7]: https://github.com/mockito/mockito/blob/main/LICENSE
[42]: http://zlika.github.io/reproducible-build-maven-plugin
[52]: https://maven.apache.org/plugins/maven-site-plugin/
[25]: https://www.gnu.org/licenses/gpl-3.0.html
[13]: https://www.apache.org/licenses/LICENSE-2.0.txt
[30]: https://maven.apache.org/enforcer/maven-enforcer-plugin/
[3]: https://www.eclipse.org/legal/epl-v20.html
[5]: http://www.opensource.org/licenses/bsd-license.php
[50]: http://maven.apache.org/plugins/maven-install-plugin/
[2]: https://junit.org/junit5/
[26]: https://sonatype.github.io/ossindex-maven/maven-plugin/
[22]: https://maven.apache.org/plugins/maven-gpg-plugin/
[10]: http://www.jqno.nl/equalsverifier
[18]: https://maven.apache.org/plugins/maven-source-plugin/
[38]: http://maven.apache.org/plugins/maven-deploy-plugin/
[20]: https://maven.apache.org/plugins/maven-javadoc-plugin/
[40]: https://github.com/exasol/error-code-crawler-maven-plugin
[48]: https://maven.apache.org/plugins/maven-jar-plugin/
2 changes: 1 addition & 1 deletion doc/changes/changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Changes

* [4.4.3](changes_4.4.3.md)
* [4.5.0](changes_4.5.0.md)
* [4.4.2](changes_4.4.2.md)
* [4.4.1](changes_4.4.1.md)
* [4.4.0](changes_4.4.0.md)
Expand Down
18 changes: 16 additions & 2 deletions doc/changes/changes_4.4.3.md → doc/changes/changes_4.5.0.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
# Exasol SQL Statement Builder 4.4.3, released 2021-09-??
# Exasol SQL Statement Builder 4.5.0, released 2021-09-30

Code name: Internal refactorings on "More Predicates"
Code name: Support more Aggregate and Analytic functions

## Summary

This release supports all aggregate and analytics functsions provided by Exasol, e.g. `GROUPING[_ID]`, `PERCENTILE_CONT`, `NTH_VALUE` and many more. See the [ticket](https://github.com/exasol/sql-statement-builder/issues/72) for a complete list.

We also added support for the keywords `DISTINCT` and `ANY` as well as the [over_clause](https://docs.exasol.com/sql_references/functions/analyticfunctions.htm?Highlight=over_clause) for analytic functions. See the [user guide](../user_guide/statements/select.md#analytic-functions) for how to use the name API.

## Features

* #72: Added support for more Aggregate and Analytic functions

## Refactoring

Expand All @@ -13,6 +23,10 @@ Code name: Internal refactorings on "More Predicates"

## Dependency Updates

### Compile Dependency Updates

* Added `com.exasol:error-reporting-java:0.4.0`

### Test Dependency Updates

* Updated `nl.jqno.equalsverifier:equalsverifier:3.6.1` to `3.7.1`
Expand Down
Loading

0 comments on commit fd2ca2a

Please sign in to comment.