You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by mm...@apache.org on 2017/09/08 16:13:38 UTC
[1/4] calcite git commit: Various tweaks [Forced Update!]
Repository: calcite
Updated Branches:
refs/heads/branch-1.14 c0adb86b0 -> 6fa983541 (forced update)
Various tweaks
They are:
* Plug some resource leaks
* Add tests for SELECT DISTINCT ... GROUP BY (they already work)
* Fix OsAdapterTest on Windows; the 'files', 'vmstat' and 'ps' tables do not work on Windows
* In checkstyle, LICENSE and NOTICE don't need header
A pull request we forgot to close in CALCITE-1959:
Close apache/calcite#529
Project: http://git-wip-us.apache.org/repos/asf/calcite/repo
Commit: http://git-wip-us.apache.org/repos/asf/calcite/commit/310eaa00
Tree: http://git-wip-us.apache.org/repos/asf/calcite/tree/310eaa00
Diff: http://git-wip-us.apache.org/repos/asf/calcite/diff/310eaa00
Branch: refs/heads/branch-1.14
Commit: 310eaa0016a21155fa3d504ba6028c81c49d0d60
Parents: 939c9a6
Author: Julian Hyde <jh...@apache.org>
Authored: Wed Aug 9 16:27:49 2017 -0700
Committer: Julian Hyde <jh...@apache.org>
Committed: Thu Sep 7 11:23:18 2017 -0700
----------------------------------------------------------------------
.../apache/calcite/test/TableFunctionTest.java | 183 ++++++++++---------
core/src/test/resources/sql/agg.iq | 67 +++++++
.../org/apache/calcite/adapter/os/SqlShell.java | 15 +-
.../calcite/adapter/os/OsAdapterTest.java | 16 +-
src/main/config/checkstyle/suppressions.xml | 2 +
5 files changed, 185 insertions(+), 98 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/calcite/blob/310eaa00/core/src/test/java/org/apache/calcite/test/TableFunctionTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/calcite/test/TableFunctionTest.java b/core/src/test/java/org/apache/calcite/test/TableFunctionTest.java
index 12392b3..fefd7d2 100644
--- a/core/src/test/java/org/apache/calcite/test/TableFunctionTest.java
+++ b/core/src/test/java/org/apache/calcite/test/TableFunctionTest.java
@@ -161,44 +161,44 @@ public class TableFunctionTest {
/** As {@link #testScannableTableFunction()} but with named parameters. */
@Test public void testMultipleScannableTableFunctionWithNamedParameters()
throws SQLException, ClassNotFoundException {
- Connection connection = DriverManager.getConnection("jdbc:calcite:");
- CalciteConnection calciteConnection =
- connection.unwrap(CalciteConnection.class);
- SchemaPlus rootSchema = calciteConnection.getRootSchema();
- SchemaPlus schema = rootSchema.add("s", new AbstractSchema());
- final TableFunction table1 = TableFunctionImpl.create(Smalls.MAZE_METHOD);
- schema.add("Maze", table1);
- final TableFunction table2 = TableFunctionImpl.create(Smalls.MAZE2_METHOD);
- schema.add("Maze", table2);
- final TableFunction table3 = TableFunctionImpl.create(Smalls.MAZE3_METHOD);
- schema.add("Maze", table3);
- final String sql = "select *\n"
- + "from table(\"s\".\"Maze\"(5, 3, 1))";
- final Statement statement = connection.createStatement();
- ResultSet resultSet = statement.executeQuery(sql);
- final String result = "S=abcde\n"
- + "S=xyz\n";
- assertThat(CalciteAssert.toString(resultSet),
- is(result + "S=generate(w=5, h=3, s=1)\n"));
+ try (Connection connection = DriverManager.getConnection("jdbc:calcite:");
+ Statement statement = connection.createStatement()) {
+ CalciteConnection calciteConnection =
+ connection.unwrap(CalciteConnection.class);
+ SchemaPlus rootSchema = calciteConnection.getRootSchema();
+ SchemaPlus schema = rootSchema.add("s", new AbstractSchema());
+ final TableFunction table1 = TableFunctionImpl.create(Smalls.MAZE_METHOD);
+ schema.add("Maze", table1);
+ final TableFunction table2 = TableFunctionImpl.create(Smalls.MAZE2_METHOD);
+ schema.add("Maze", table2);
+ final TableFunction table3 = TableFunctionImpl.create(Smalls.MAZE3_METHOD);
+ schema.add("Maze", table3);
+ final String sql = "select *\n"
+ + "from table(\"s\".\"Maze\"(5, 3, 1))";
+ ResultSet resultSet = statement.executeQuery(sql);
+ final String result = "S=abcde\n"
+ + "S=xyz\n";
+ assertThat(CalciteAssert.toString(resultSet),
+ is(result + "S=generate(w=5, h=3, s=1)\n"));
- final String sql2 = "select *\n"
- + "from table(\"s\".\"Maze\"(WIDTH => 5, HEIGHT => 3, SEED => 1))";
- resultSet = statement.executeQuery(sql2);
- assertThat(CalciteAssert.toString(resultSet),
- is(result + "S=generate2(w=5, h=3, s=1)\n"));
+ final String sql2 = "select *\n"
+ + "from table(\"s\".\"Maze\"(WIDTH => 5, HEIGHT => 3, SEED => 1))";
+ resultSet = statement.executeQuery(sql2);
+ assertThat(CalciteAssert.toString(resultSet),
+ is(result + "S=generate2(w=5, h=3, s=1)\n"));
- final String sql3 = "select *\n"
- + "from table(\"s\".\"Maze\"(HEIGHT => 3, WIDTH => 5))";
- resultSet = statement.executeQuery(sql3);
- assertThat(CalciteAssert.toString(resultSet),
- is(result + "S=generate2(w=5, h=3, s=null)\n"));
+ final String sql3 = "select *\n"
+ + "from table(\"s\".\"Maze\"(HEIGHT => 3, WIDTH => 5))";
+ resultSet = statement.executeQuery(sql3);
+ assertThat(CalciteAssert.toString(resultSet),
+ is(result + "S=generate2(w=5, h=3, s=null)\n"));
- final String sql4 = "select *\n"
- + "from table(\"s\".\"Maze\"(FOO => 'a'))";
- resultSet = statement.executeQuery(sql4);
- assertThat(CalciteAssert.toString(resultSet),
- is(result + "S=generate3(foo=a)\n"));
- connection.close();
+ final String sql4 = "select *\n"
+ + "from table(\"s\".\"Maze\"(FOO => 'a'))";
+ resultSet = statement.executeQuery(sql4);
+ assertThat(CalciteAssert.toString(resultSet),
+ is(result + "S=generate3(foo=a)\n"));
+ }
}
/**
@@ -264,31 +264,32 @@ public class TableFunctionTest {
+ "could not be implemented")
@Test public void testTableFunctionCursorInputs()
throws SQLException, ClassNotFoundException {
- Connection connection =
- DriverManager.getConnection("jdbc:calcite:");
- CalciteConnection calciteConnection =
- connection.unwrap(CalciteConnection.class);
- SchemaPlus rootSchema = calciteConnection.getRootSchema();
- SchemaPlus schema = rootSchema.add("s", new AbstractSchema());
- final TableFunction table =
- TableFunctionImpl.create(Smalls.GENERATE_STRINGS_METHOD);
- schema.add("GenerateStrings", table);
- final TableFunction add =
- TableFunctionImpl.create(Smalls.PROCESS_CURSOR_METHOD);
- schema.add("process", add);
- final PreparedStatement ps = connection.prepareStatement("select *\n"
- + "from table(\"s\".\"process\"(2,\n"
- + "cursor(select * from table(\"s\".\"GenerateStrings\"(?)))\n"
- + ")) as t(u)\n"
- + "where u > 3");
- ps.setInt(1, 5);
- ResultSet resultSet = ps.executeQuery();
- // GenerateStrings returns 0..4, then 2 is added (process function),
- // thus 2..6, finally where u > 3 leaves just 4..6
- assertThat(CalciteAssert.toString(resultSet),
- equalTo("u=4\n"
- + "u=5\n"
- + "u=6\n"));
+ try (Connection connection =
+ DriverManager.getConnection("jdbc:calcite:")) {
+ CalciteConnection calciteConnection =
+ connection.unwrap(CalciteConnection.class);
+ SchemaPlus rootSchema = calciteConnection.getRootSchema();
+ SchemaPlus schema = rootSchema.add("s", new AbstractSchema());
+ final TableFunction table =
+ TableFunctionImpl.create(Smalls.GENERATE_STRINGS_METHOD);
+ schema.add("GenerateStrings", table);
+ final TableFunction add =
+ TableFunctionImpl.create(Smalls.PROCESS_CURSOR_METHOD);
+ schema.add("process", add);
+ final PreparedStatement ps = connection.prepareStatement("select *\n"
+ + "from table(\"s\".\"process\"(2,\n"
+ + "cursor(select * from table(\"s\".\"GenerateStrings\"(?)))\n"
+ + ")) as t(u)\n"
+ + "where u > 3");
+ ps.setInt(1, 5);
+ ResultSet resultSet = ps.executeQuery();
+ // GenerateStrings returns 0..4, then 2 is added (process function),
+ // thus 2..6, finally where u > 3 leaves just 4..6
+ assertThat(CalciteAssert.toString(resultSet),
+ equalTo("u=4\n"
+ + "u=5\n"
+ + "u=6\n"));
+ }
}
/**
@@ -298,37 +299,37 @@ public class TableFunctionTest {
+ "could not be implemented")
@Test public void testTableFunctionCursorsInputs()
throws SQLException, ClassNotFoundException {
- Connection connection =
- getConnectionWithMultiplyFunction();
- CalciteConnection calciteConnection =
- connection.unwrap(CalciteConnection.class);
- SchemaPlus rootSchema = calciteConnection.getRootSchema();
- SchemaPlus schema = rootSchema.getSubSchema("s");
- final TableFunction table =
- TableFunctionImpl.create(Smalls.GENERATE_STRINGS_METHOD);
- schema.add("GenerateStrings", table);
- final TableFunction add =
- TableFunctionImpl.create(Smalls.PROCESS_CURSORS_METHOD);
- schema.add("process", add);
- final PreparedStatement ps = connection.prepareStatement("select *\n"
- + "from table(\"s\".\"process\"(2,\n"
- + "cursor(select * from table(\"s\".\"multiplication\"(5,5,0))),\n"
- + "cursor(select * from table(\"s\".\"GenerateStrings\"(?)))\n"
- + ")) as t(u)\n"
- + "where u > 3");
- ps.setInt(1, 5);
- ResultSet resultSet = ps.executeQuery();
- // GenerateStrings produce 0..4
- // multiplication produce 1..5
- // process sums and adds 2
- // sum is 2 + 1..9 == 3..9
- assertThat(CalciteAssert.toString(resultSet),
- equalTo("u=4\n"
- + "u=5\n"
- + "u=6\n"
- + "u=7\n"
- + "u=8\n"
- + "u=9\n"));
+ try (Connection connection = getConnectionWithMultiplyFunction()) {
+ CalciteConnection calciteConnection =
+ connection.unwrap(CalciteConnection.class);
+ SchemaPlus rootSchema = calciteConnection.getRootSchema();
+ SchemaPlus schema = rootSchema.getSubSchema("s");
+ final TableFunction table =
+ TableFunctionImpl.create(Smalls.GENERATE_STRINGS_METHOD);
+ schema.add("GenerateStrings", table);
+ final TableFunction add =
+ TableFunctionImpl.create(Smalls.PROCESS_CURSORS_METHOD);
+ schema.add("process", add);
+ final PreparedStatement ps = connection.prepareStatement("select *\n"
+ + "from table(\"s\".\"process\"(2,\n"
+ + "cursor(select * from table(\"s\".\"multiplication\"(5,5,0))),\n"
+ + "cursor(select * from table(\"s\".\"GenerateStrings\"(?)))\n"
+ + ")) as t(u)\n"
+ + "where u > 3");
+ ps.setInt(1, 5);
+ ResultSet resultSet = ps.executeQuery();
+ // GenerateStrings produce 0..4
+ // multiplication produce 1..5
+ // process sums and adds 2
+ // sum is 2 + 1..9 == 3..9
+ assertThat(CalciteAssert.toString(resultSet),
+ equalTo("u=4\n"
+ + "u=5\n"
+ + "u=6\n"
+ + "u=7\n"
+ + "u=8\n"
+ + "u=9\n"));
+ }
}
@Test public void testUserDefinedTableFunction() {
http://git-wip-us.apache.org/repos/asf/calcite/blob/310eaa00/core/src/test/resources/sql/agg.iq
----------------------------------------------------------------------
diff --git a/core/src/test/resources/sql/agg.iq b/core/src/test/resources/sql/agg.iq
index ba97052..a56ca09 100755
--- a/core/src/test/resources/sql/agg.iq
+++ b/core/src/test/resources/sql/agg.iq
@@ -62,6 +62,73 @@ select count(deptno, ename, 1, deptno) as c from emp;
!ok
+# DISTINCT and GROUP BY
+select distinct deptno, count(*) as c from emp group by deptno;
++--------+---+
+| DEPTNO | C |
++--------+---+
+| 10 | 2 |
+| 20 | 1 |
+| 30 | 2 |
+| 50 | 2 |
+| 60 | 1 |
+| | 1 |
++--------+---+
+(6 rows)
+
+!ok
+
+select distinct deptno from emp group by deptno;
++--------+
+| DEPTNO |
++--------+
+| 10 |
+| 20 |
+| 30 |
+| 50 |
+| 60 |
+| |
++--------+
+(6 rows)
+
+!ok
+
+select distinct count(*) as c from emp group by deptno;
++---+
+| C |
++---+
+| 1 |
+| 2 |
++---+
+(2 rows)
+
+!ok
+
+select distinct count(*) as c from emp group by deptno having count(*) > 1;
++---+
+| C |
++---+
+| 2 |
++---+
+(1 row)
+
+!ok
+
+select distinct count(*) as c from emp group by deptno order by deptno desc;
+Expression 'DEPTNO' is not in the select clause
+!error
+
+select distinct count(*) as c from emp group by deptno order by 1 desc;
++---+
+| C |
++---+
+| 2 |
+| 1 |
++---+
+(2 rows)
+
+!ok
+
# [CALCITE-998] Exception when calling STDDEV_SAMP, STDDEV_POP
# stddev_samp
select stddev_samp(deptno) as s from emp;
http://git-wip-us.apache.org/repos/asf/calcite/blob/310eaa00/plus/src/main/java/org/apache/calcite/adapter/os/SqlShell.java
----------------------------------------------------------------------
diff --git a/plus/src/main/java/org/apache/calcite/adapter/os/SqlShell.java b/plus/src/main/java/org/apache/calcite/adapter/os/SqlShell.java
index bf91b41..6cdbfab 100644
--- a/plus/src/main/java/org/apache/calcite/adapter/os/SqlShell.java
+++ b/plus/src/main/java/org/apache/calcite/adapter/os/SqlShell.java
@@ -121,12 +121,10 @@ public class SqlShell {
+ "default), 'csv',\n"
+ " 'headers', 'json', 'mysql'\n"
+ " -h --help Print this help";
- try (Connection connection = DriverManager.getConnection(url);
- Statement s = connection.createStatement()) {
- final StringBuilder b = new StringBuilder();
- final Enumerator<String> args =
- Linq4j.asEnumerable(this.args).enumerator();
- Format format = Format.SPACED;
+ final StringBuilder b = new StringBuilder();
+ Format format = Format.SPACED;
+ try (Enumerator<String> args =
+ Linq4j.asEnumerable(this.args).enumerator()) {
while (args.moveNext()) {
if (args.current().equals("-o")) {
if (args.moveNext()) {
@@ -150,6 +148,11 @@ public class SqlShell {
b.append(args.current());
}
}
+ }
+ try (Connection connection = DriverManager.getConnection(url);
+ Statement s = connection.createStatement();
+ Enumerator<String> args =
+ Linq4j.asEnumerable(this.args).enumerator()) {
final ResultSet r = s.executeQuery(b.toString());
format.output(out, r);
r.close();
http://git-wip-us.apache.org/repos/asf/calcite/blob/310eaa00/plus/src/test/java/org/apache/calcite/adapter/os/OsAdapterTest.java
----------------------------------------------------------------------
diff --git a/plus/src/test/java/org/apache/calcite/adapter/os/OsAdapterTest.java b/plus/src/test/java/org/apache/calcite/adapter/os/OsAdapterTest.java
index 69d142b..c1cd78e 100644
--- a/plus/src/test/java/org/apache/calcite/adapter/os/OsAdapterTest.java
+++ b/plus/src/test/java/org/apache/calcite/adapter/os/OsAdapterTest.java
@@ -22,10 +22,12 @@ import org.apache.calcite.runtime.Hook;
import org.apache.calcite.sql.validate.SqlConformanceEnum;
import org.apache.calcite.test.CalciteAssert;
import org.apache.calcite.util.Holder;
+import org.apache.calcite.util.Util;
import com.google.common.base.Function;
import org.hamcrest.CoreMatchers;
+import org.junit.Assume;
import org.junit.Test;
import java.io.ByteArrayInputStream;
@@ -58,6 +60,10 @@ import static org.junit.Assert.fail;
* </ul>
*/
public class OsAdapterTest {
+ private static boolean isWindows() {
+ return System.getProperty("os.name").startsWith("Windows");
+ }
+
@Test public void testDu() {
sql("select * from du")
.returns(
@@ -98,12 +104,16 @@ public class OsAdapterTest {
}
@Test public void testFiles() {
+ Assume.assumeFalse("Skip: the 'files' table does not work on Windows",
+ isWindows());
sql("select distinct type from files")
.returnsUnordered("type=d",
"type=f");
}
@Test public void testPs() {
+ Assume.assumeFalse("Skip: the 'ps' table does not work on Windows",
+ isWindows());
sql("select * from ps")
.returns(
new Function<ResultSet, Void>() {
@@ -126,6 +136,8 @@ public class OsAdapterTest {
}
@Test public void testPsDistinct() {
+ Assume.assumeFalse("Skip: the 'ps' table does not work on Windows",
+ isWindows());
sql("select distinct `user` from ps")
.returns(
new Function<ResultSet, Void>() {
@@ -166,6 +178,8 @@ public class OsAdapterTest {
}
@Test public void testVmstat() {
+ Assume.assumeFalse("Skip: the 'files' table does not work on Windows",
+ isWindows());
sql("select * from vmstat")
.returns(
new Function<ResultSet, Void>() {
@@ -304,7 +318,7 @@ public class OsAdapterTest {
final StringWriter errSw = new StringWriter();
final PrintWriter err = new PrintWriter(errSw);
new SqlShell(in, out, err, args).run();
- return outSw.toString();
+ return Util.toLinux(outSw.toString());
}
@Test public void testSqlShellHelp() throws SQLException {
http://git-wip-us.apache.org/repos/asf/calcite/blob/310eaa00/src/main/config/checkstyle/suppressions.xml
----------------------------------------------------------------------
diff --git a/src/main/config/checkstyle/suppressions.xml b/src/main/config/checkstyle/suppressions.xml
index 2f55a52..b76afb7 100644
--- a/src/main/config/checkstyle/suppressions.xml
+++ b/src/main/config/checkstyle/suppressions.xml
@@ -21,6 +21,8 @@ limitations under the License.
<suppressions>
<!-- Suppress checks on generated files. -->
<suppress checks="Header" files="CalciteResource.properties"/>
+ <suppress checks="Header" files="LICENSE"/>
+ <suppress checks="Header" files="NOTICE"/>
<suppress checks=".*" files="org-apache-calcite-jdbc.properties"/>
<suppress checks=".*" files="Foo.java"/>
<suppress checks=".*" files=".*[/\\]target[/\\]maven-archiver[/\\]pom.properties"/>
[3/4] calcite git commit: Update Coverity URL in documentation
Posted by mm...@apache.org.
Update Coverity URL in documentation
Project: http://git-wip-us.apache.org/repos/asf/calcite/repo
Commit: http://git-wip-us.apache.org/repos/asf/calcite/commit/86c7c3f7
Tree: http://git-wip-us.apache.org/repos/asf/calcite/tree/86c7c3f7
Diff: http://git-wip-us.apache.org/repos/asf/calcite/diff/86c7c3f7
Branch: refs/heads/branch-1.14
Commit: 86c7c3f76e2588a52045ab6f86afa6a29d807225
Parents: 172db20
Author: Michael Mior <mm...@uwaterloo.ca>
Authored: Thu Sep 7 13:46:40 2017 -0400
Committer: Michael Mior <mm...@uwaterloo.ca>
Committed: Thu Sep 7 23:36:22 2017 -0400
----------------------------------------------------------------------
site/_docs/howto.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/calcite/blob/86c7c3f7/site/_docs/howto.md
----------------------------------------------------------------------
diff --git a/site/_docs/howto.md b/site/_docs/howto.md
index bf6682e..8743163 100644
--- a/site/_docs/howto.md
+++ b/site/_docs/howto.md
@@ -449,7 +449,7 @@ Before you start:
* `-Dcalcite.test.mongodb`
* `-Dcalcite.test.splunk`
* Trigger a
- <a href="https://scan.coverity.com/projects/2966">Coverity scan</a>
+ <a href="https://scan.coverity.com/projects/julianhyde-calcite">Coverity scan</a>
by merging the latest code into the `julianhyde/coverity_scan` branch,
and when it completes, make sure that there are no important issues.
* Add release notes to `site/_docs/history.md`. Include the commit history,
[2/4] calcite git commit: [CALCITE-1947] Add time/timestamp with
local time zone types to optimizer
Posted by mm...@apache.org.
[CALCITE-1947] Add time/timestamp with local time zone types to optimizer
* Fixes javadoc
Project: http://git-wip-us.apache.org/repos/asf/calcite/repo
Commit: http://git-wip-us.apache.org/repos/asf/calcite/commit/172db20b
Tree: http://git-wip-us.apache.org/repos/asf/calcite/tree/172db20b
Diff: http://git-wip-us.apache.org/repos/asf/calcite/diff/172db20b
Branch: refs/heads/branch-1.14
Commit: 172db20b2571c676465ccf58e2fd1475748906e9
Parents: 310eaa0
Author: Jesus Camacho Rodriguez <jc...@apache.org>
Authored: Thu Sep 7 15:58:29 2017 -0700
Committer: Jesus Camacho Rodriguez <jc...@apache.org>
Committed: Thu Sep 7 15:58:29 2017 -0700
----------------------------------------------------------------------
core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/calcite/blob/172db20b/core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java
----------------------------------------------------------------------
diff --git a/core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java b/core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java
index f9a61fc..02bb385 100644
--- a/core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java
+++ b/core/src/test/java/org/apache/calcite/rex/RexBuilderTest.java
@@ -179,7 +179,7 @@ public class RexBuilderTest {
}
/** Tests
- * {@link RexBuilder#makeTimestampWithLocalTimeZoneLiteral(TimestampWithTimeZoneString, int)}. */
+ * {@link RexBuilder#makeTimestampWithLocalTimeZoneLiteral(TimestampString, int)}. */
@Test public void testTimestampWithLocalTimeZoneLiteral() {
final RelDataTypeFactory typeFactory =
new SqlTypeFactoryImpl(RelDataTypeSystem.DEFAULT);
[4/4] calcite git commit: [CALCITE-1970] Release Calcite 1.14.0
Posted by mm...@apache.org.
[CALCITE-1970] Release Calcite 1.14.0
Project: http://git-wip-us.apache.org/repos/asf/calcite/repo
Commit: http://git-wip-us.apache.org/repos/asf/calcite/commit/6fa98354
Tree: http://git-wip-us.apache.org/repos/asf/calcite/tree/6fa98354
Diff: http://git-wip-us.apache.org/repos/asf/calcite/diff/6fa98354
Branch: refs/heads/branch-1.14
Commit: 6fa9835417611fa924c070597bf98fbe50f63f30
Parents: 86c7c3f
Author: Michael Mior <mm...@uwaterloo.ca>
Authored: Mon Aug 28 17:03:37 2017 -0400
Committer: Michael Mior <mm...@uwaterloo.ca>
Committed: Thu Sep 7 23:47:51 2017 -0400
----------------------------------------------------------------------
README | 2 +-
pom.xml | 2 +-
site/_docs/history.md | 84 ++++++++++++++++++++++++++++++++++++++++++++--
site/_docs/howto.md | 4 +--
4 files changed, 86 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/calcite/blob/6fa98354/README
----------------------------------------------------------------------
diff --git a/README b/README
index 48b3d4a..b2cd7e3 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
-Apache Calcite release 1.13.0
+Apache Calcite release 1.14.0
This is a source or binary distribution of Apache Calcite.
http://git-wip-us.apache.org/repos/asf/calcite/blob/6fa98354/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 46e4dd6..35d40dc 100644
--- a/pom.xml
+++ b/pom.xml
@@ -49,7 +49,7 @@ limitations under the License.
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<top.dir>${project.basedir}</top.dir>
<version.major>1</version.major>
- <version.minor>13</version.minor>
+ <version.minor>14</version.minor>
<!-- This list is in alphabetical order. -->
<airlift-tpch.version>0.1</airlift-tpch.version>
http://git-wip-us.apache.org/repos/asf/calcite/blob/6fa98354/site/_docs/history.md
----------------------------------------------------------------------
diff --git a/site/_docs/history.md b/site/_docs/history.md
index a3f1919..9218cdf 100644
--- a/site/_docs/history.md
+++ b/site/_docs/history.md
@@ -28,7 +28,17 @@ For a full list of releases, see
Downloads are available on the
[downloads page]({{ site.baseurl }}/downloads/).
-## <a href="https://github.com/apache/calcite/releases/tag/calcite-1.14.0">1.14.0</a> / under development
+## <a href="https://github.com/apache/calcite/releases/tag/calcite-1.15.0">1.15.0</a> / under development
+{: #v1-15-0}
+
+Compatibility: This release is tested
+on Linux, macOS, Microsoft Windows;
+using Oracle JDK 1.7, 1.8, 9;
+Guava versions 14.0 to 21.0;
+Druid version 0.10.0;
+other software versions as specified in `pom.xml`.
+
+## <a href="https://github.com/apache/calcite/releases/tag/calcite-1.14.0">1.14.0</a> / 2017-09-06
{: #v1-14-0}
Compatibility: This release is tested
@@ -38,14 +48,84 @@ Guava versions 14.0 to 21.0;
Druid version 0.10.0;
other software versions as specified in `pom.xml`.
+#### New features
+
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1968">CALCITE-1968</a>] OpenGIS Simple Feature Access SQL 1.2.1: add `GEOMETRY` data type and first 35 functions
+ Add Spatial page, document GIS functions in SQL reference (indicating
+ which ones are implemented), and add "countries" data set for testing.
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1967">CALCITE-1967</a>] Elasticsearch 5 adapter (Christian Beikov)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1911">CALCITE-1911</a>] In `MATCH_RECOGNIZE`, support `WITHIN` sub-clause (Dian Fu)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1897">CALCITE-1897</a>] Add '%' operator as an alternative to 'MOD' (sunjincheng)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1787">CALCITE-1787</a>] Add ThetaSketch and HyperUnique support to Calcite via rolled up columns (Zain Humayun)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1896">CALCITE-1896</a>] OS adapter and sqlsh
+ * Vmstat table function for sqlsh
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1864">CALCITE-1864</a>] Allow `NULL` literal as argument
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1834">CALCITE-1834</a>] Allow user-defined functions to have arguments that are `ARRAY` or `MULTISET` (Ankit Singhal)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1886">CALCITE-1886</a>] Support `"LIMIT [offset,] row_count"`, per MySQL (Kaiwang Chen)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1845">CALCITE-1845</a>] Quantified comparison predicates (SOME, ANY, ALL)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1709">CALCITE-1709</a>] Support mixing table columns with extended columns in DML (Rajeshbabu Chintaguntla)
+
#### Bug-fixes, API changes and minor enhancements
-* [<a href="https://issues.apache.org/jira/browse/CALCITE-1931">CALCITE-1931</a>]
+* [<a href="https://issues.apache.org/jira/browse/<a href="https://issues.apache.org/jira/browse/CALCITE-1931">CALCITE-1931</a>">CALCITE-1931</a>]
Change the return type of RANK and other aggregate functions.
Various aggregate functions that used to return `INTEGER` now return other
types: `RANK`, `DENSE_RANK`, and `NTILE` now return `BIGINT`;
`CUME_DIST` and `PERCENT_RANK` now return `DOUBLE`.
(**This is a breaking change**.)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1947">CALCITE-1947</a>] Add `TIME`/`TIMESTAMP` with local time zone types to optimizer
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1972">CALCITE-1972</a>] Create `.sha512` and `.md5` digests for release artifacts
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1941">CALCITE-1941</a>] Refine interface `Schema#snapshot()`
+ (**This is a breaking change**.)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1069">CALCITE-1069</a>] In `Aggregate`, deprecate indicators, and allow `GROUPING` to be used as an aggregate function
+ (**This is a breaking change**.)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1969">CALCITE-1969</a>] Annotate user-defined functions as strict and semi-strict
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1945">CALCITE-1945</a>] Make return types of `AVG`, `VARIANCE`, `STDDEV` and `COVAR` customizable via RelDataTypeSystem
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1966">CALCITE-1966</a>] Allow normal views to act as materialization table (Christian Beikov)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1953">CALCITE-1953</a>] Rewrite `"NOT (x IS FALSE)" to "x IS NOT FALSE"; "x IS TRUE"` would be wrong
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1943">CALCITE-1943</a>] Add back `NavigationExpander` and `NavigationReplacer` in `SqlValidatorImpl` (Dian Fu)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1963">CALCITE-1963</a>] Upgrade checkstyle, and fix code to comply
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1944">CALCITE-1944</a>] Window function applied to sub-query that returns dynamic star gets wrong plan (Volodymyr Vysotskyi)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1954">CALCITE-1954</a>] Column from outer join should be null, whether or not it is aliased
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1959">CALCITE-1959</a>] Reduce the amount of metadata and `tableName` calls in Druid (Zain Humayun)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1930">CALCITE-1930</a>] Fix `AggregateExpandDistinctAggregatesRule` when there are multiple `AggregateCalls` referring to the same input
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1936">CALCITE-1936</a>] Allow `ROUND()` and `TRUNCATE()` to take one operand, defaulting scale to 0
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1931">CALCITE-1931</a>] Change the return type of RANK and other aggregate functions
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1932">CALCITE-1932</a>] `Project.getPermutation()` should return null if not a permutation (e.g. repeated `InputRef`)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1925">CALCITE-1925</a>] In `JaninoRelMetadataProvider`, cache null values (Ted Xu)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1849">CALCITE-1849</a>] Support `RexSubQuery` in `RelToSqlConverter`
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1909">CALCITE-1909</a>] Output `rowType` of Match should include `PARTITION BY` and `ORDER BY` columns
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1929">CALCITE-1929</a>] Deprecate class `RelDataTypeFactory.FieldInfoBuilder`
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1895">CALCITE-1895</a>] MSSQL's SUBSTRING operator has different syntax (Chris Baynes)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1919">CALCITE-1919</a>] `NullPointerException` when target in `ReflectiveSchema` belongs to root package (Lim Chee Hau)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1907">CALCITE-1907</a>] Table function with 1 column gives `ClassCastException`
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1841">CALCITE-1841</a>] Create handlers for JDBC dialect-specific generated SQL (Chris Baynes)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1898">CALCITE-1898</a>] `LIKE` must match '.' (period) literally
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1900">CALCITE-1900</a>] Detect cyclic views and give useful error message
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1893">CALCITE-1893</a>] Add MYSQL_5 conformance
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1883">CALCITE-1883</a>] `HepPlanner` should force garbage collect whenever a root registered (Ted Xu)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1889">CALCITE-1889</a>] Accept compound identifiers in `SqlValidatorUtil.checkIdentifierListForDuplicates()` (Rajeshbabu Chintaguntla)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1881">CALCITE-1881</a>] Can't distinguish overloaded user-defined functions that have DATE and TIMESTAMP arguments (余启)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1803">CALCITE-1803</a>] Push Project that follows Aggregate down to Druid (Junxian Wu)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1828">CALCITE-1828</a>] Push the FILTER clause into Druid as a Filtered Aggregator (Zain Humayun)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1871">CALCITE-1871</a>] Nesting `LAST` within `PREV` is not parsed correctly for `MATCH_RECOGNIZE`
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1877">CALCITE-1877</a>] Move the Pig test data files into target for the test runtime
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1815">CALCITE-1815</a>] Switch Pig adapter to depend on avatica-core instead of full avatica
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1826">CALCITE-1826</a>] Generate dialect-specific SQL for `FLOOR` operator when in a `GROUP BY` (Chris Baynes)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1842">CALCITE-1842</a>] `Sort.computeSelfCost()`` calls `makeCost()`` with arguments in wrong order (Junxian Wu)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1874">CALCITE-1874</a>] In Frameworks, make `SqlToRelConverter` configurable
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1873">CALCITE-1873</a>] In a "GROUP BY ordinal" query, validator gives invalid "Expression is not being grouped" error if column has alias
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1833">CALCITE-1833</a>] User-defined aggregate functions with more than one parameter (hzyuemeng1)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1860">CALCITE-1860</a>] Duplicate null predicates cause `NullPointerException` in `RexUtil` (Ruidong Li)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1859">CALCITE-1859</a>] NPE in validate method of `VolcanoPlanner`
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1818">CALCITE-1818</a>] Handle `SqlKind.DYNAMIC` (parameters) in `SqlImplementor` (Dylan Adams)
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1856">CALCITE-1856</a>] Add option `StructKind.PEEK_FIELDS_NO_EXPAND`, similar to `PEEK_FIELDS` but is not expanded in `"SELECT *"` (Shuyi Chen)
+
+#### Web site and documentation
+
+* Add committer Chris Baynes
+* Add DataEngConf talk
+* [<a href="https://issues.apache.org/jira/browse/CALCITE-1901">CALCITE-1901</a>] SQL reference should say that "ONLY" is required after "FETCH ... ROWS"
## <a href="https://github.com/apache/calcite/releases/tag/calcite-1.13.0">1.13.0</a> / 2017-06-20
{: #v1-13-0}
http://git-wip-us.apache.org/repos/asf/calcite/blob/6fa98354/site/_docs/howto.md
----------------------------------------------------------------------
diff --git a/site/_docs/howto.md b/site/_docs/howto.md
index 8743163..5defff4 100644
--- a/site/_docs/howto.md
+++ b/site/_docs/howto.md
@@ -39,8 +39,8 @@ Unpack the source distribution `.tar.gz` or `.zip` file,
then build using maven:
{% highlight bash %}
-$ tar xvfz calcite-1.13.0-source.tar.gz
-$ cd calcite-1.13.0
+$ tar xvfz calcite-1.14.0-source.tar.gz
+$ cd calcite-1.14.0
$ mvn install
{% endhighlight %}