[jira] [Updated] (CALCITE-3039) In Interpreter, min() incorrectly returns maximum double value
[ https://issues.apache.org/jira/browse/CALCITE-3039?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Hongze Zhang updated CALCITE-3039: -- Summary: In Interpreter, min() incorrectly returns maximum double value (was: In interpreter, min() incorrectly returns maximum double value) > In Interpreter, min() incorrectly returns maximum double value > -- > > Key: CALCITE-3039 > URL: https://issues.apache.org/jira/browse/CALCITE-3039 > Project: Calcite > Issue Type: Bug > Components: core >Affects Versions: 1.17.0 >Reporter: dijkspicy >Priority: Major > Labels: easyfix, pull-request-available > Time Spent: 20m > Remaining Estimate: 0h > > {code:java} > //代码占位符 > /** Implementation of {@code MIN} function to calculate the minimum of > * {@code float} values as a user-defined aggregate. > */ > public static class MinFloat extends NumericComparison { > public MinFloat() { > super(Float.MAX_VALUE, Math::min); > } > } > /** Implementation of {@code MIN} function to calculate the minimum of > * {@code double} and {@code real} values as a user-defined aggregate. > */ > public static class MinDouble extends NumericComparison { > public MinDouble() { > super(Double.MAX_VALUE, Math::max); > } > } > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Resolved] (CALCITE-3029) Java-oriented field type is wrongly forced to be NOT NULL after being converted to SQL-oriented
[ https://issues.apache.org/jira/browse/CALCITE-3029?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Hongze Zhang resolved CALCITE-3029. --- Resolution: Fixed Fixed in [37002c1399cea1464b5d53c0fc4e5ec90f831f1b|https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=37002c1399cea1464b5d53c0fc4e5ec90f831f1b]. Thanks for the review, [~rubenql], [~zabetak], [~danny0405]! > Java-oriented field type is wrongly forced to be NOT NULL after being > converted to SQL-oriented > --- > > Key: CALCITE-3029 > URL: https://issues.apache.org/jira/browse/CALCITE-3029 > Project: Calcite > Issue Type: Bug >Affects Versions: 1.19.0 >Reporter: Hongze Zhang >Assignee: Hongze Zhang >Priority: Major > Labels: pull-request-available > Fix For: 1.20.0 > > Time Spent: 2h 10m > Remaining Estimate: 0h > > A Java-oriented field type loses its nullable constraint after calling method > {{org.apache.calcite.jdbc.JavaTypeFactoryImpl#toSql(org.apache.calcite.rel.type.RelDataType)}}. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-2741) Add operator table with Hive-specific built-in functions
[ https://issues.apache.org/jira/browse/CALCITE-2741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830061#comment-16830061 ] Lai Zhou commented on CALCITE-2741: --- hi,[~julianhyde] , [~zabetak],[~zhztheplayer], [~hyuan],[~francischuang] I create a new adapter of Calcite that support hive sql queries on dataset. Since the extensions is made base on Calcite 1.18.0, I pushed the project to a new codebase. [[https://github.com/51nb/marble]|[https://github.com/51nb/marble]]. And I proposed a Table API to make it easy to execute a sql query. We use it in our company's core financial business to unify the way to compute lots of model variables . This project shows how we extend Calcite core to support hive sql queries, it may be helpful to people who wants to build a customized sql engine on top of Calcite. > Add operator table with Hive-specific built-in functions > > > Key: CALCITE-2741 > URL: https://issues.apache.org/jira/browse/CALCITE-2741 > Project: Calcite > Issue Type: New Feature > Components: core >Reporter: Lai Zhou >Priority: Minor > > [~julianhyde], > I write a hive adapter for calcite to support Hive sql ,includes > UDF、UDAF、UDTF and some of SqlSpecialOperator. > How do you think of supporting a direct implemention of hive sql like this? > I think it will be valueable when someone want to migrate his hive etl jobs > to real-time scene. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-2741) Add operator table with Hive-specific built-in functions
[ https://issues.apache.org/jira/browse/CALCITE-2741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830061#comment-16830061 ] Lai Zhou edited comment on CALCITE-2741 at 4/30/19 8:30 AM: hi,[~julianhyde] , [~zabetak],[~zhztheplayer], [~hyuan],[~francischuang] I create a new adapter of Calcite that support hive sql queries on dataset. Since the extensions is made base on Calcite 1.18.0, I pushed the project to a new codebase: [https://github.com/51nb/marble] And I proposed a Table API to make it easy to execute a sql query. We use it in our company's core financial business to unify the way to compute lots of model variables . This project shows how we extend Calcite core to support hive sql queries, it may be helpful to people who wants to build a customized sql engine on top of Calcite. was (Author: hhlai1990): hi,[~julianhyde] , [~zabetak],[~zhztheplayer], [~hyuan],[~francischuang] I create a new adapter of Calcite that support hive sql queries on dataset. Since the extensions is made base on Calcite 1.18.0, I pushed the project to a new codebase. [[https://github.com/51nb/marble]|[https://github.com/51nb/marble]]. And I proposed a Table API to make it easy to execute a sql query. We use it in our company's core financial business to unify the way to compute lots of model variables . This project shows how we extend Calcite core to support hive sql queries, it may be helpful to people who wants to build a customized sql engine on top of Calcite. > Add operator table with Hive-specific built-in functions > > > Key: CALCITE-2741 > URL: https://issues.apache.org/jira/browse/CALCITE-2741 > Project: Calcite > Issue Type: New Feature > Components: core >Reporter: Lai Zhou >Priority: Minor > > [~julianhyde], > I write a hive adapter for calcite to support Hive sql ,includes > UDF、UDAF、UDTF and some of SqlSpecialOperator. > How do you think of supporting a direct implemention of hive sql like this? > I think it will be valueable when someone want to migrate his hive etl jobs > to real-time scene. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-2741) Add operator table with Hive-specific built-in functions
[ https://issues.apache.org/jira/browse/CALCITE-2741?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830061#comment-16830061 ] Lai Zhou edited comment on CALCITE-2741 at 4/30/19 9:40 AM: hi,[~julianhyde] , [~zabetak],[~zhztheplayer], [~hyuan],[~francischuang] I create a new adapter of Calcite that supports hive sql queries on dataset. Since the extensions is made base on Calcite 1.18.0, I pushed the project to a new codebase: [https://github.com/51nb/marble] And I proposed a Table API to make it easy to execute a sql query. We use it in our company's core financial business to unify the way to compute lots of model variables . This project shows how we extend Calcite core to support hive sql queries, it may be helpful to people who wants to build a customized sql engine on top of Calcite. was (Author: hhlai1990): hi,[~julianhyde] , [~zabetak],[~zhztheplayer], [~hyuan],[~francischuang] I create a new adapter of Calcite that support hive sql queries on dataset. Since the extensions is made base on Calcite 1.18.0, I pushed the project to a new codebase: [https://github.com/51nb/marble] And I proposed a Table API to make it easy to execute a sql query. We use it in our company's core financial business to unify the way to compute lots of model variables . This project shows how we extend Calcite core to support hive sql queries, it may be helpful to people who wants to build a customized sql engine on top of Calcite. > Add operator table with Hive-specific built-in functions > > > Key: CALCITE-2741 > URL: https://issues.apache.org/jira/browse/CALCITE-2741 > Project: Calcite > Issue Type: New Feature > Components: core >Reporter: Lai Zhou >Priority: Minor > > [~julianhyde], > I write a hive adapter for calcite to support Hive sql ,includes > UDF、UDAF、UDTF and some of SqlSpecialOperator. > How do you think of supporting a direct implemention of hive sql like this? > I think it will be valueable when someone want to migrate his hive etl jobs > to real-time scene. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Resolved] (CALCITE-3030) SqlParseException when using component identifier for setting in merge statements
[ https://issues.apache.org/jira/browse/CALCITE-3030?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Stamatis Zampetakis resolved CALCITE-3030. -- Resolution: Fixed Fix Version/s: 1.20.0 Fixed in [e3a69708df55cf05bbe38f8f1d5bd472cf8de81f|https://github.com/apache/calcite/commit/e3a69708df55cf05bbe38f8f1d5bd472cf8de81f]. Thanks a lot [~danny0405] for such a quick reaction;) > SqlParseException when using component identifier for setting in merge > statements > - > > Key: CALCITE-3030 > URL: https://issues.apache.org/jira/browse/CALCITE-3030 > Project: Calcite > Issue Type: Bug > Components: core >Affects Versions: 1.19.0 > Environment: OS: win10 (17763) > JDK: 1.7 >Reporter: wuzq >Assignee: Danny Chan >Priority: Major > Labels: pull-request-available > Fix For: 1.20.0 > > Attachments: wx20190428-204...@2x.png > > Time Spent: 20m > Remaining Estimate: 0h > > The update section of "merge SQL" reports an error when using an alias > {code:java} > // if i replace red code with "b = '123456'", I don't get an error > String sql = "merge into xxx as t1 using yyy as t2 on t1.a = t2.a when > matched then update set t1.b = '123456'" ; > SqlParser.ConfigBuilder configBuilder = SqlParser.configBuilder(); > configBuilder.setCaseSensitive(false); > SqlParser.Config config = configBuilder.build(); > SqlParser parser = SqlParser.create(sql, config); > SqlNode node = parser.parseQuery(); > {code} > the error > {code:java} > //代码占位符 > Exception in thread "main" org.apache.calcite.sql.parser.SqlParseException: > Encountered "." at line 1, column 84. > Was expecting: > "=" ... > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.convertException(SqlParserImpl.java:355) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.normalizeException(SqlParserImpl.java:143) > at org.apache.calcite.sql.parser.SqlParser.parseQuery(SqlParser.java:156) > at com.yatop.Calcite.main(Calcite.java:39) > Caused by: org.apache.calcite.sql.parser.impl.ParseException: Encountered "." > at line 1, column 84. > Was expecting: > "=" ... > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.generateParseException(SqlParserImpl.java:25299) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.jj_consume_token(SqlParserImpl.java:25116) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.WhenMatchedClause(SqlParserImpl.java:1414) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.SqlMerge(SqlParserImpl.java:1383) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.SqlStmt(SqlParserImpl.java:861) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.SqlStmtEof(SqlParserImpl.java:877) > at > org.apache.calcite.sql.parser.impl.SqlParserImpl.parseSqlStmtEof(SqlParserImpl.java:199) > at org.apache.calcite.sql.parser.SqlParser.parseQuery(SqlParser.java:148) > ... 1 more > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Created] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
Andrew Pilloud created CALCITE-3040: --- Summary: Avatica drops exception messages starting in 1.14.0 Key: CALCITE-3040 URL: https://issues.apache.org/jira/browse/CALCITE-3040 Project: Calcite Issue Type: Bug Components: avatica Affects Versions: avatica-1.14.0 Environment: SQLline 1.4.0 Beam 2.13.0-SNAPSHOT Avatica 1.14.0 [https://github.com/apache/beam/pull/8437] Reporter: Andrew Pilloud With Avatica 1.13.0 we get detailed exceptions: {code:java} Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) 0: BeamSQL> create external table testing (a int) type text location '/tmp/test'; No rows affected (0.246 seconds) 0: BeamSQL> set runner = bogus; No rows affected (0.009 seconds) 0: BeamSQL> select * from testing; Error: Error while executing SQL "select * from testing": Unknown 'runner' specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) 0: BeamSQL> {code} In 1.14.0 the details of the failure are missing: {code:java} Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) 0: BeamSQL> create external table testing (a int) type text location '/tmp/test'; No rows affected (0.244 seconds) 0: BeamSQL> set runner = bogus; No rows affected (0.009 seconds) 0: BeamSQL> select * from testing; Error: Error while executing SQL "select * from testing" (state=,code=0) 0: BeamSQL> {code} This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830639#comment-16830639 ] Julian Hyde commented on CALCITE-3040: -- I don't take a position whether the new behavior is more or less "correct" than the old behavior. Though clearly it is a regression, if reasonable clients are broken by the change. I think SQLLine should be able to handle both forms of error stack. If you agree, can you log a SQLLine issue. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: SQLline 1.4.0 > Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830646#comment-16830646 ] Julian Hyde commented on CALCITE-3040: -- [~vlsi] Would you like to comment on this? > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: SQLline 1.4.0 > Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830656#comment-16830656 ] Vladimir Sitnikov commented on CALCITE-3040: [~apilloud], have you contacted Sqlline? I think Sqlline should just print cause exceptions somewhere the lines behind https://github.com/julianhyde/sqlline/blob/7577f3ebaca0897a9ff01d1553d4576487e1d2c3/src/main/java/sqlline/SqlLine.java#L1523-L1531 > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: SQLline 1.4.0 > Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830657#comment-16830657 ] Vladimir Sitnikov commented on CALCITE-3040: [~julianhyde], your turn. I don't think "top level SQLException" was ever supposed to contain ALL the information regarding a failure. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: SQLline 1.4.0 > Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830656#comment-16830656 ] Vladimir Sitnikov edited comment on CALCITE-3040 at 4/30/19 8:17 PM: - [~apilloud], have you contacted Sqlline? I think Sqlline should just print cause exceptions somewhere around the lines of https://github.com/julianhyde/sqlline/blob/7577f3ebaca0897a9ff01d1553d4576487e1d2c3/src/main/java/sqlline/SqlLine.java#L1523-L1531 was (Author: vladimirsitnikov): [~apilloud], have you contacted Sqlline? I think Sqlline should just print cause exceptions somewhere the lines behind https://github.com/julianhyde/sqlline/blob/7577f3ebaca0897a9ff01d1553d4576487e1d2c3/src/main/java/sqlline/SqlLine.java#L1523-L1531 > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: SQLline 1.4.0 > Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Updated] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Andrew Pilloud updated CALCITE-3040: Environment: Beam 2.13.0-SNAPSHOT Avatica 1.14.0 [https://github.com/apache/beam/pull/8437] was: SQLline 1.4.0 Beam 2.13.0-SNAPSHOT Avatica 1.14.0 [https://github.com/apache/beam/pull/8437] > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830670#comment-16830670 ] Andrew Pilloud commented on CALCITE-3040: - This is not a SQLLine specific issue. It occurs with many common JDBC UIs. For example, SQL Workbench/J Before: {code:java} An error occurred when executing the SQL command: select * from testing Error while executing SQL "select * from testing": Unknown 'runner' specified 'bogus', supported pipeline runners [DirectRunner] 1 statement failed. Execution time: 0.67s {code} After: {code:java} An error occurred when executing the SQL command: select * from testing Error while executing SQL "select * from testing" 1 statement failed. Execution time: 0.71s {code} > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830674#comment-16830674 ] Andrew Pilloud commented on CALCITE-3040: - SQuirreL SQL before: {code:java} Error: Error while executing SQL "select * from testing": Unknown 'runner' specified 'bogus', supported pipeline runners [DirectRunner] SQLState: null ErrorCode: 0 {code} After: {code:java} Error: Error while executing SQL "SELECT * from testing" SQLState: null ErrorCode: 0 {code} > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830680#comment-16830680 ] Kai Jiang commented on CALCITE-3040: Is that because the exception stack trace has been suppress? https://github.com/apache/calcite-avatica/pull/84/files#diff-c8672103ebe8b1e2e7e7c18115dc4695 the top of stack trace has been truncated. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830680#comment-16830680 ] Kai Jiang edited comment on CALCITE-3040 at 4/30/19 8:49 PM: - Is that because the exception stack trace has been suppress? https://github.com/apache/calcite-avatica/pull/84/files#diff-c8672103ebe8b1e2e7e7c18115dc4695 looks like the top of stack trace has been truncated. was (Author: vectorijk): Is that because the exception stack trace has been suppress? https://github.com/apache/calcite-avatica/pull/84/files#diff-c8672103ebe8b1e2e7e7c18115dc4695 the top of stack trace has been truncated. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830680#comment-16830680 ] Kai Jiang edited comment on CALCITE-3040 at 4/30/19 8:59 PM: - looks like the top of stack trace has been truncated. was (Author: vectorijk): Is that because the exception stack trace has been suppress? https://github.com/apache/calcite-avatica/pull/84/files#diff-c8672103ebe8b1e2e7e7c18115dc4695 looks like the top of stack trace has been truncated. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830692#comment-16830692 ] Vladimir Sitnikov commented on CALCITE-3040: Well, {{SQLException(String reason, Throwable cause)}} is there since Java 1.6 (December 2006), and {{Throwable#initCause}} was added in 1.4 (February 2002). I guess clients might just need be updated to account "new" APIs. Technically speaking, there's a fun relationship: 1) OpenJDK uses {{Throwable#toString}} for {{printStackTrace}} implementation 2) SQL clients that do not know of {{getCause}} seem to use {{getMessage}}. Then Avatica can play a devil hack: sub-class SQLException and override {{toString}} to be different from {{getMessage}}. However it would stop the progress even more since everybody would assume "getCause" is not required in decent SQL clients. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Created] (CALCITE-3041) Query runs endless when setImportance to 0
Haisheng Yuan created CALCITE-3041: -- Summary: Query runs endless when setImportance to 0 Key: CALCITE-3041 URL: https://issues.apache.org/jira/browse/CALCITE-3041 Project: Calcite Issue Type: Bug Components: core Reporter: Haisheng Yuan Make the following changes: {code:java} --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { // aggregate functions, add a project for the same effect. relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); } +call.getPlanner().setImportance(aggregate, 0.0); call.transformTo(relBuilder.build()); } } {code} The query in {{JdbcTest.testGroupBy1Max1}} will run endless. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830692#comment-16830692 ] Vladimir Sitnikov edited comment on CALCITE-3040 at 4/30/19 9:09 PM: - Well, {{SQLException(String reason, Throwable cause)}} is there since Java 1.6 (December 2006), and {{Throwable#initCause}} was added in 1.4 (February 2002). I guess clients might just need be updated to account "new" APIs. Technically speaking, there's a fun relationship: 1) OpenJDK uses {{Throwable#toString}} for {{printStackTrace}} implementation 2) SQL clients that do not know of {{getCause}} seem to use {{getMessage}}. Then Avatica can play a devil hack: sub-class SQLException and override {{toString}} to be different from {{getMessage}}. In other words it could return just "while executing SQL select..." for {{toString}} (so {{printStackTrace}} is does not duplicate things), and {{getMessage}} could walk all the exceptions and collect the messages (so the one who uses "just" {{getMessage}} still receives all the messages). However it would stop the progress even more since everybody would assume "getCause" is not required in decent SQL clients. was (Author: vladimirsitnikov): Well, {{SQLException(String reason, Throwable cause)}} is there since Java 1.6 (December 2006), and {{Throwable#initCause}} was added in 1.4 (February 2002). I guess clients might just need be updated to account "new" APIs. Technically speaking, there's a fun relationship: 1) OpenJDK uses {{Throwable#toString}} for {{printStackTrace}} implementation 2) SQL clients that do not know of {{getCause}} seem to use {{getMessage}}. Then Avatica can play a devil hack: sub-class SQLException and override {{toString}} to be different from {{getMessage}}. However it would stop the progress even more since everybody would assume "getCause" is not required in decent SQL clients. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Updated] (CALCITE-3041) Query runs endless when setImportance to 0
[ https://issues.apache.org/jira/browse/CALCITE-3041?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Haisheng Yuan updated CALCITE-3041: --- Description: Make the following changes: {code:java} --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { // aggregate functions, add a project for the same effect. relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); } +call.getPlanner().setImportance(aggregate, 0.0); call.transformTo(relBuilder.build()); } } {code} The query in {{JdbcTest.testGroupBy1Max1}} will run endless. was: Make the following changes: {code:diff} --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { // aggregate functions, add a project for the same effect. relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); } +call.getPlanner().setImportance(aggregate, 0.0); call.transformTo(relBuilder.build()); } } {code} The query in {{JdbcTest.testGroupBy1Max1}} will run endless. > Query runs endless when setImportance to 0 > -- > > Key: CALCITE-3041 > URL: https://issues.apache.org/jira/browse/CALCITE-3041 > Project: Calcite > Issue Type: Bug > Components: core >Reporter: Haisheng Yuan >Priority: Major > > Make the following changes: > {code:java} > --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { >// aggregate functions, add a project for the same effect. > > relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); > } > +call.getPlanner().setImportance(aggregate, 0.0); > call.transformTo(relBuilder.build()); >} > } > {code} > The query in {{JdbcTest.testGroupBy1Max1}} will run endless. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Updated] (CALCITE-3041) Query runs endless when setImportance to 0
[ https://issues.apache.org/jira/browse/CALCITE-3041?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Haisheng Yuan updated CALCITE-3041: --- Description: Make the following changes: {code:diff} --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { // aggregate functions, add a project for the same effect. relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); } +call.getPlanner().setImportance(aggregate, 0.0); call.transformTo(relBuilder.build()); } } {code} The query in {{JdbcTest.testGroupBy1Max1}} will run endless. was: Make the following changes: {code:java} --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { // aggregate functions, add a project for the same effect. relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); } +call.getPlanner().setImportance(aggregate, 0.0); call.transformTo(relBuilder.build()); } } {code} The query in {{JdbcTest.testGroupBy1Max1}} will run endless. > Query runs endless when setImportance to 0 > -- > > Key: CALCITE-3041 > URL: https://issues.apache.org/jira/browse/CALCITE-3041 > Project: Calcite > Issue Type: Bug > Components: core >Reporter: Haisheng Yuan >Priority: Major > > Make the following changes: > {code:diff} > --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { >// aggregate functions, add a project for the same effect. > > relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); > } > +call.getPlanner().setImportance(aggregate, 0.0); > call.transformTo(relBuilder.build()); >} > } > {code} > The query in {{JdbcTest.testGroupBy1Max1}} will run endless. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830716#comment-16830716 ] Julian Hyde commented on CALCITE-3040: -- It is really very simple. If it breaks common clients, then it is a bug. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Comment Edited] (CALCITE-2282) Allow OperatorTable to be pluggable in the parser
[ https://issues.apache.org/jira/browse/CALCITE-2282?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830001#comment-16830001 ] Lai Zhou edited comment on CALCITE-2282 at 5/1/19 2:01 AM: --- [~zhztheplayer] ,thanks, you're right. " That said, you can put a operator with same NAME, KIND to your own table, then validator will use it to replace the original one" It really works. I don't need to rewrite the Parser.jj to replace DIVIDE. I forgot my new solutions for DIVIDE in last comment. Here is my code: {code:java} newOp = new SqlBinaryOperator(upName, operatorInSqlStdOperatorTable.getKind(), operatorInSqlStdOperatorTable.getLeftPrec(), operatorInSqlStdOperatorTable.getRightPrec(), HiveSqlUDFReturnTypeInference.INSTANCE, null, HiveSqlFunction.ArgChecker.INSTANCE); newOp = new SqlPrefixOperator(upName, operatorInSqlStdOperatorTable.getKind(), operatorInSqlStdOperatorTable.getLeftPrec(), operatorInSqlStdOperatorTable.getRightPrec(), HiveSqlUDFReturnTypeInference.INSTANCE, null, HiveSqlFunction.ArgChecker.INSTANCE); register(newOp); {code} If we put an operator with same NAME, KIND,SqlSyntax to replace the original one, we'd better keep the same class `SqlBinaryOperator` or `SqlPrefixOperator`. So I introduced a new constructor for them to construct the Operator. as [~julianhyde] said, "Another technique could be a visitor that walks over expressions and replaces Calcite's DIVIDE with Hive's DIVIDE." It also works . Thanks. was (Author: hhlai1990): [~zhztheplayer] ,thanks, you're right. " That said, you can put a operator with same NAME, KIND to your own table, then validator will use it to replace the original one" It really works. I don't need to rewrite the Parser.jj to replace DIVIDE. I forgot my new solutions for DIVIDE in last comment. Here is my code: {code:java} newOp = new SqlBinaryOperator(upName, operatorInSqlStdOperatorTable.getKind(), operatorInSqlStdOperatorTable.getLeftPrec(), operatorInSqlStdOperatorTable.getRightPrec(), HiveSqlUDFReturnTypeInference.INSTANCE, null, HiveSqlFunction.ArgChecker.INSTANCE); newOp = new SqlPrefixOperator(upName, operatorInSqlStdOperatorTable.getKind(), operatorInSqlStdOperatorTable.getLeftPrec(), operatorInSqlStdOperatorTable.getRightPrec(), HiveSqlUDFReturnTypeInference.INSTANCE, null, HiveSqlFunction.ArgChecker.INSTANCE); register(newOp); {code} If we put an operator with same NAME, KIND to replace the original one, we'd better keep the same class `SqlBinaryOperator` or `SqlPrefixOperator`. So I introduced a new constructor for them to construct the Operator. as [~julianhyde] said, "Another technique could be a visitor that walks over expressions and replaces Calcite's DIVIDE with Hive's DIVIDE." It also works . Thanks. > Allow OperatorTable to be pluggable in the parser > - > > Key: CALCITE-2282 > URL: https://issues.apache.org/jira/browse/CALCITE-2282 > Project: Calcite > Issue Type: Improvement > Components: core >Reporter: Sudheesh Katkam >Priority: Major > Attachments: CALCITE-2282.patch.txt > > > SqlAbstractParserImpl [hardcodes OperatorTable to > SqlStdOperatorTable|https://github.com/apache/calcite/blob/8327e674e7f0a768d124fa37fd75cda4b8a35bb6/core/src/main/java/org/apache/calcite/sql/parser/SqlAbstractParserImpl.java#L334|https://github.com/apache/calcite/blob/8327e674e7f0a768d124fa37fd75cda4b8a35bb6/core/src/main/java/org/apache/calcite/sql/parser/SqlAbstractParserImpl.java#L334]. > Make this pluggable via a protected method. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Assigned] (CALCITE-3041) Query runs endless when setImportance to 0
[ https://issues.apache.org/jira/browse/CALCITE-3041?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Danny Chan reassigned CALCITE-3041: --- Assignee: Danny Chan > Query runs endless when setImportance to 0 > -- > > Key: CALCITE-3041 > URL: https://issues.apache.org/jira/browse/CALCITE-3041 > Project: Calcite > Issue Type: Bug > Components: core >Reporter: Haisheng Yuan >Assignee: Danny Chan >Priority: Major > > Make the following changes: > {code:java} > --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { >// aggregate functions, add a project for the same effect. > > relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); > } > +call.getPlanner().setImportance(aggregate, 0.0); > call.transformTo(relBuilder.build()); >} > } > {code} > The query in {{JdbcTest.testGroupBy1Max1}} will run endless. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3041) Query runs endless when setImportance to 0
[ https://issues.apache.org/jira/browse/CALCITE-3041?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830814#comment-16830814 ] Danny Chan commented on CALCITE-3041: - [~hyuan] I would like to take this. > Query runs endless when setImportance to 0 > -- > > Key: CALCITE-3041 > URL: https://issues.apache.org/jira/browse/CALCITE-3041 > Project: Calcite > Issue Type: Bug > Components: core >Reporter: Haisheng Yuan >Assignee: Danny Chan >Priority: Major > > Make the following changes: > {code:java} > --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { >// aggregate functions, add a project for the same effect. > > relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); > } > +call.getPlanner().setImportance(aggregate, 0.0); > call.transformTo(relBuilder.build()); >} > } > {code} > The query in {{JdbcTest.testGroupBy1Max1}} will run endless. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Closed] (CALCITE-3036) Remove correlate variables from Join
[ https://issues.apache.org/jira/browse/CALCITE-3036?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Danny Chan closed CALCITE-3036. --- Resolution: Won't Fix This task has been canceled, see CALCITE-2969 discussion. > Remove correlate variables from Join > > > Key: CALCITE-3036 > URL: https://issues.apache.org/jira/browse/CALCITE-3036 > Project: Calcite > Issue Type: Improvement > Components: core >Reporter: Danny Chan >Assignee: Danny Chan >Priority: Major > Fix For: 1.20.0 > > -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Updated] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Francis Chuang updated CALCITE-3040: Fix Version/s: avatica-1.15.0 > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > Fix For: avatica-1.15.0 > > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3041) Query runs endless when setImportance to 0
[ https://issues.apache.org/jira/browse/CALCITE-3041?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830844#comment-16830844 ] Haisheng Yuan commented on CALCITE-3041: [~danny0405] Go ahead, thanks! > Query runs endless when setImportance to 0 > -- > > Key: CALCITE-3041 > URL: https://issues.apache.org/jira/browse/CALCITE-3041 > Project: Calcite > Issue Type: Bug > Components: core >Reporter: Haisheng Yuan >Assignee: Danny Chan >Priority: Major > > Make the following changes: > {code:java} > --- a/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > +++ b/core/src/main/java/org/apache/calcite/rel/rules/AggregateRemoveRule.java > @@ -123,6 +123,7 @@ public void onMatch(RelOptRuleCall call) { >// aggregate functions, add a project for the same effect. > > relBuilder.project(relBuilder.fields(aggregate.getGroupSet().asList())); > } > +call.getPlanner().setImportance(aggregate, 0.0); > call.transformTo(relBuilder.build()); >} > } > {code} > The query in {{JdbcTest.testGroupBy1Max1}} will run endless. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Created] (CALCITE-3042) Fix minor bugs in Avatica-Go docker release script
Francis Chuang created CALCITE-3042: --- Summary: Fix minor bugs in Avatica-Go docker release script Key: CALCITE-3042 URL: https://issues.apache.org/jira/browse/CALCITE-3042 Project: Calcite Issue Type: Bug Components: avatica-go Reporter: Francis Chuang Assignee: Francis Chuang Fix For: avatica-go-5.0.0 There are some minor bugs in the docker release script: * In the voting email generated, some incorrect variables were used. * Promoting a release fails, because it checks out the wrong folder from the dev release repo. -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Created] (CALCITE-3043) Add additional functionality to docker release script
Francis Chuang created CALCITE-3043: --- Summary: Add additional functionality to docker release script Key: CALCITE-3043 URL: https://issues.apache.org/jira/browse/CALCITE-3043 Project: Calcite Issue Type: Bug Components: avatica Reporter: Francis Chuang Assignee: Francis Chuang Fix For: avatica-1.15.0 Add support for (similar to the functionality that was implemented for avatica-go): * Uploading a release to svn using docker * Promoting a release using docker -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830877#comment-16830877 ] Stamatis Zampetakis commented on CALCITE-3040: -- I assume this change breaks only unit tests which expect the message in a specific place. I've notice this when testing against Calcite for the vote of Avatica 1.14.0 but I it didn't seem to me like a big issue since I considered that it is easy to rewrite the tests and check for the detailed message in another place (getCause). I think it was a mistake from our side that we didn't specify this behavior in the release note but the change overall seemed meaningful when I checked the PR. [~apilloud] this is a regression but it is supposed to improve the exception messages. Wouldn't you consider modifying the tests on your side? > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > Fix For: avatica-1.15.0 > > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Commented] (CALCITE-3040) Avatica drops exception messages starting in 1.14.0
[ https://issues.apache.org/jira/browse/CALCITE-3040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16830878#comment-16830878 ] Stamatis Zampetakis commented on CALCITE-3040: -- I've just seen that we already decided (dev list) to make a new release for this, so please ignore my previous message. > Avatica drops exception messages starting in 1.14.0 > --- > > Key: CALCITE-3040 > URL: https://issues.apache.org/jira/browse/CALCITE-3040 > Project: Calcite > Issue Type: Bug > Components: avatica >Affects Versions: avatica-1.14.0 > Environment: Beam 2.13.0-SNAPSHOT > Avatica 1.14.0 > [https://github.com/apache/beam/pull/8437] >Reporter: Andrew Pilloud >Priority: Major > Fix For: avatica-1.15.0 > > > With Avatica 1.13.0 we get detailed exceptions: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.246 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing": Unknown 'runner' > specified 'bogus', supported pipeline runners [DirectRunner] (state=,code=0) > 0: BeamSQL> > {code} > In 1.14.0 the details of the failure are missing: > {code:java} > Welcome to Beam SQL 2.13.0-SNAPSHOT (based on sqlline version 1.4.0) > 0: BeamSQL> create external table testing (a int) type text location > '/tmp/test'; > No rows affected (0.244 seconds) > 0: BeamSQL> set runner = bogus; > No rows affected (0.009 seconds) > 0: BeamSQL> select * from testing; > Error: Error while executing SQL "select * from testing" (state=,code=0) > 0: BeamSQL> > {code} > This appears to be caused by CALCITE-2845 -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Resolved] (CALCITE-3043) Add additional functionality to docker release script
[ https://issues.apache.org/jira/browse/CALCITE-3043?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Francis Chuang resolved CALCITE-3043. - Resolution: Fixed > Add additional functionality to docker release script > - > > Key: CALCITE-3043 > URL: https://issues.apache.org/jira/browse/CALCITE-3043 > Project: Calcite > Issue Type: Bug > Components: avatica >Reporter: Francis Chuang >Assignee: Francis Chuang >Priority: Major > Fix For: avatica-1.15.0 > > > Add support for (similar to the functionality that was implemented for > avatica-go): > * Uploading a release to svn using docker > * Promoting a release using docker -- This message was sent by Atlassian JIRA (v7.6.3#76005)
[jira] [Created] (CALCITE-3044) Add avatica 1.15.0 to travis tests for avatica-go
Francis Chuang created CALCITE-3044: --- Summary: Add avatica 1.15.0 to travis tests for avatica-go Key: CALCITE-3044 URL: https://issues.apache.org/jira/browse/CALCITE-3044 Project: Calcite Issue Type: Bug Components: avatica-go Reporter: Francis Chuang Assignee: Francis Chuang Fix For: avatica-go-5.0.0 -- This message was sent by Atlassian JIRA (v7.6.3#76005)