[GitHub] [calcite] JiajunBernoulli commented on a diff in pull request #3422: [CALCITE-5999] DECIMAL literals as sometimes unparsed looking as DOUBLE literals

2023-09-16 Thread via GitHub
JiajunBernoulli commented on code in PR #3422: URL: https://github.com/apache/calcite/pull/3422#discussion_r1327919480 ## core/src/main/java/org/apache/calcite/sql/SqlNumericLiteral.java: ## @@ -90,7 +90,7 @@ public boolean isExact() { @Override public String toValue() {

[GitHub] [calcite] JiajunBernoulli commented on a diff in pull request #3429: [CALCITE-6006] RelToSqlConverter loses charset information

2023-09-16 Thread via GitHub
JiajunBernoulli commented on code in PR #3429: URL: https://github.com/apache/calcite/pull/3429#discussion_r1327921769 ## core/src/main/java/org/apache/calcite/rel/rel2sql/SqlImplementor.java: ## @@ -1409,8 +1411,20 @@ public static SqlNode toSql(RexLiteral literal) {

[GitHub] [calcite] libenchao commented on a diff in pull request #3419: [CALCITE-5988] SqlImplementor.toSql cannot emit VARBINARY literals

2023-09-16 Thread via GitHub
libenchao commented on code in PR #3419: URL: https://github.com/apache/calcite/pull/3419#discussion_r1327919801 ## core/src/main/java/org/apache/calcite/rel/rel2sql/SqlImplementor.java: ## @@ -1437,6 +1437,8 @@ public static SqlNode toSql(RexLiteral literal) { return

[GitHub] [calcite] JiajunBernoulli commented on a diff in pull request #3423: [CALCITE-5997] OFFSET operator is incorrectly unparsed

2023-09-16 Thread via GitHub
JiajunBernoulli commented on code in PR #3423: URL: https://github.com/apache/calcite/pull/3423#discussion_r1327918095 ## core/src/main/java/org/apache/calcite/sql/fun/SqlItemOperator.java: ## @@ -50,13 +50,19 @@ public class SqlItemOperator extends SqlSpecialOperator {

[GitHub] [calcite] JiajunBernoulli commented on a diff in pull request #3423: [CALCITE-5997] OFFSET operator is incorrectly unparsed

2023-09-16 Thread via GitHub
JiajunBernoulli commented on code in PR #3423: URL: https://github.com/apache/calcite/pull/3423#discussion_r1327918311 ## core/src/main/java/org/apache/calcite/sql/fun/SqlItemOperator.java: ## @@ -78,7 +84,24 @@ public SqlItemOperator(String name, SqlWriter writer,

[GitHub] [calcite] Jiabao-Sun commented on a diff in pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
Jiabao-Sun commented on code in PR #3430: URL: https://github.com/apache/calcite/pull/3430#discussion_r1327990074 ## testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java: ## @@ -9314,11 +9314,12 @@ private static void checkGroupConcatFuncFails(SqlOperatorFixture

[GitHub] [calcite] Jiabao-Sun commented on a diff in pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
Jiabao-Sun commented on code in PR #3430: URL: https://github.com/apache/calcite/pull/3430#discussion_r1327989243 ## testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java: ## @@ -9314,11 +9314,12 @@ private static void checkGroupConcatFuncFails(SqlOperatorFixture

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3430: URL: https://github.com/apache/calcite/pull/3430#discussion_r1327999598 ## testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java: ## @@ -9314,11 +9314,12 @@ private static void checkGroupConcatFuncFails(SqlOperatorFixture

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3423: [CALCITE-5997] OFFSET operator is incorrectly unparsed

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3423: URL: https://github.com/apache/calcite/pull/3423#discussion_r1327988723 ## core/src/main/java/org/apache/calcite/sql/fun/SqlItemOperator.java: ## @@ -78,7 +84,24 @@ public SqlItemOperator(String name, SqlWriter writer, SqlCall

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3422: [CALCITE-5999] DECIMAL literals as sometimes unparsed looking as DOUBLE literals

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3422: URL: https://github.com/apache/calcite/pull/3422#issuecomment-1722278860 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3422: [CALCITE-5999] DECIMAL literals as sometimes unparsed looking as DOUBLE literals

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3422: URL: https://github.com/apache/calcite/pull/3422#issuecomment-1722278855 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3422: [CALCITE-5999] DECIMAL literals as sometimes unparsed looking as DOUBLE literals

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3422: URL: https://github.com/apache/calcite/pull/3422#discussion_r1327986850 ## core/src/main/java/org/apache/calcite/sql/SqlNumericLiteral.java: ## @@ -90,7 +90,7 @@ public boolean isExact() { @Override public String toValue() {

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3430: URL: https://github.com/apache/calcite/pull/3430#discussion_r1327987695 ## testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java: ## @@ -9314,11 +9314,12 @@ private static void checkGroupConcatFuncFails(SqlOperatorFixture

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3430: URL: https://github.com/apache/calcite/pull/3430#issuecomment-1722277272 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3423: [CALCITE-5997] OFFSET operator is incorrectly unparsed

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3423: URL: https://github.com/apache/calcite/pull/3423#issuecomment-1722282842 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] Jiabao-Sun commented on a diff in pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
Jiabao-Sun commented on code in PR #3430: URL: https://github.com/apache/calcite/pull/3430#discussion_r1327999465 ## testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java: ## @@ -9314,11 +9314,12 @@ private static void checkGroupConcatFuncFails(SqlOperatorFixture

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3418: [CALCITE-5994] Add the optimize for removing the redundant sort when a sort's input max row cnt is 1

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3418: URL: https://github.com/apache/calcite/pull/3418#issuecomment-1722252721 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] macroguo-ghy commented on a diff in pull request #3416: [CALCITE-4189] Simplify 'p OR (p IS NOT TRUE)' to 'TRUE'

2023-09-16 Thread via GitHub
macroguo-ghy commented on code in PR #3416: URL: https://github.com/apache/calcite/pull/3416#discussion_r1327973848 ## core/src/main/java/org/apache/calcite/rex/RexSimplify.java: ## @@ -2060,6 +2060,25 @@ private RexNode simplifyOrs(List terms, RexUnknownAs unknownAs) {

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3429: [CALCITE-6006] RelToSqlConverter loses charset information

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3429: URL: https://github.com/apache/calcite/pull/3429#discussion_r1327984728 ## core/src/main/java/org/apache/calcite/rel/rel2sql/SqlImplementor.java: ## @@ -1409,8 +1411,20 @@ public static SqlNode toSql(RexLiteral literal) {

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3429: [CALCITE-6006] RelToSqlConverter loses charset information

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3429: URL: https://github.com/apache/calcite/pull/3429#discussion_r1327984728 ## core/src/main/java/org/apache/calcite/rel/rel2sql/SqlImplementor.java: ## @@ -1409,8 +1411,20 @@ public static SqlNode toSql(RexLiteral literal) {

[GitHub] [calcite] Jiabao-Sun commented on pull request #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
Jiabao-Sun commented on PR #3430: URL: https://github.com/apache/calcite/pull/3430#issuecomment-1722273127 Hi @julianhyde, could you help review it when you have time? Thanks a lot. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3416: [CALCITE-4189] Simplify 'p OR (p IS NOT TRUE)' to 'TRUE'

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3416: URL: https://github.com/apache/calcite/pull/3416#issuecomment-1722255920 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] Jiabao-Sun opened a new pull request, #3430: [CALCITE-6008] ARRAY_AGG should returns ARRAY NULL when there's no input rows

2023-09-16 Thread via GitHub
Jiabao-Sun opened a new pull request, #3430: URL: https://github.com/apache/calcite/pull/3430 ARRAY_AGG in BigQuery and Postgres returns NULL if there are zero input rows or expression evaluates to NULL for all rows. However, it will return `ARRAY NOT NULL` in the return type of the

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3416: [CALCITE-4189] Simplify 'p OR (p IS NOT TRUE)' to 'TRUE'

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3416: URL: https://github.com/apache/calcite/pull/3416#issuecomment-1722255036 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] macroguo-ghy commented on pull request #3416: [CALCITE-4189] Simplify 'p OR (p IS NOT TRUE)' to 'TRUE'

2023-09-16 Thread via GitHub
macroguo-ghy commented on PR #3416: URL: https://github.com/apache/calcite/pull/3416#issuecomment-1722256355 Hi, @kgyrtkirk. Sorry for late of response, I was a little busy this week. I did some changes, would you like to review this PR again? -- This is an automated message from the

[GitHub] [calcite] mihaibudiu commented on a diff in pull request #3419: [CALCITE-5988] SqlImplementor.toSql cannot emit VARBINARY literals

2023-09-16 Thread via GitHub
mihaibudiu commented on code in PR #3419: URL: https://github.com/apache/calcite/pull/3419#discussion_r1327984159 ## core/src/main/java/org/apache/calcite/rel/rel2sql/SqlImplementor.java: ## @@ -1437,6 +1437,8 @@ public static SqlNode toSql(RexLiteral literal) { return

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3416: [CALCITE-4189] Simplify 'p OR (p IS NOT TRUE)' to 'TRUE'

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3416: URL: https://github.com/apache/calcite/pull/3416#issuecomment-1722244273 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png

[GitHub] [calcite] macroguo-ghy commented on pull request #3417: [CALCITE-5993] Add CODE_POINTS_TO_STRING, TO_CODE_POINTS function (en…

2023-09-16 Thread via GitHub
macroguo-ghy commented on PR #3417: URL: https://github.com/apache/calcite/pull/3417#issuecomment-1722388454 Hi @tanclary, Thanks for your review, and sorry for late response, I was a litter busy this week. I do some change and add some comments, would you like to review this PR again?

[GitHub] [calcite] JiajunBernoulli commented on a diff in pull request #3423: [CALCITE-5997] OFFSET operator is incorrectly unparsed

2023-09-16 Thread via GitHub
JiajunBernoulli commented on code in PR #3423: URL: https://github.com/apache/calcite/pull/3423#discussion_r1328048733 ## testkit/src/main/java/org/apache/calcite/sql/parser/SqlParserTest.java: ## @@ -725,6 +725,37 @@ protected static SortedSet keywords(@Nullable String

[GitHub] [calcite] macroguo-ghy commented on a diff in pull request #3417: [CALCITE-5993] Add CODE_POINTS_TO_STRING, TO_CODE_POINTS function (en…

2023-09-16 Thread via GitHub
macroguo-ghy commented on code in PR #3417: URL: https://github.com/apache/calcite/pull/3417#discussion_r1328039931 ## core/src/main/java/org/apache/calcite/runtime/SqlFunctions.java: ## @@ -1130,14 +1130,68 @@ public static String charFromUtf8(int n) { assert codePoint

[GitHub] [calcite] sonarcloud[bot] commented on pull request #3417: [CALCITE-5993] Add CODE_POINTS_TO_STRING, TO_CODE_POINTS function (en…

2023-09-16 Thread via GitHub
sonarcloud[bot] commented on PR #3417: URL: https://github.com/apache/calcite/pull/3417#issuecomment-1722389393 Kudos, SonarCloud Quality Gate passed! [![Quality Gate passed](https://sonarsource.github.io/sonarcloud-github-static-resources/v2/checks/QualityGateBadge/passed-16px.png