Skip to content

Commit 3ca040c

Browse files
authored
Fix UT failure and Linkchecker failure (#4809)
1 parent 7b30c9b commit 3ca040c

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

docs/dev/intro-v3-architecture.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ In Linkedin, they created a internal Calcite repo to convert Pig Latin scripts i
9898
- Have an optimizer rule to optimize Pig group/cogroup into Aggregate operators
9999
- Implement other RelNode in Rel2Sql so that Pig Latin can be translated into SQL
100100

101-
This [work](https://issues.apache.org/jira/browse/CALCITE-3122) had contributed to Apache Calcite and named [Piglet](https://calcite.apache.org/javadocAggregate/org/apache/calcite/piglet/package-summary.html). It allows users to write queries in Pig Latin, and execute them using any applicable Calcite adapter.
101+
This work had contributed to Apache Calcite \(CALCITE-3122\) and named [Piglet](https://calcite.apache.org/javadocAggregate/org/apache/calcite/piglet/package-summary.html). It allows users to write queries in Pig Latin, and execute them using any applicable Calcite adapter.
102102

103103
Pig Latin leverage `RelBuilder` to implement as a third-part front-end language (dialect).
104104

ppl/src/test/java/org/opensearch/sql/ppl/calcite/CalcitePPLArrayFunctionTest.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ public void testMvindexSingleElementPositive() {
127127
verifyResult(root, expectedResult);
128128

129129
String expectedSparkSql =
130-
"SELECT `array`('a', 'b', 'c')[1 + 1] `result`\n" + "FROM `scott`.`EMP`\n" + "LIMIT 1";
130+
"SELECT ARRAY('a', 'b', 'c')[1 + 1] `result`\n" + "FROM `scott`.`EMP`\n" + "LIMIT 1";
131131
verifyPPLToSparkSQL(root, expectedSparkSql);
132132
}
133133

@@ -152,7 +152,7 @@ public void testMvindexSingleElementNegative() {
152152
verifyResult(root, expectedResult);
153153

154154
String expectedSparkSql =
155-
"SELECT `array`('a', 'b', 'c')[ARRAY_LENGTH(`array`('a', 'b', 'c')) + -1 + 1]"
155+
"SELECT ARRAY('a', 'b', 'c')[ARRAY_LENGTH(ARRAY('a', 'b', 'c')) + -1 + 1]"
156156
+ " `result`\n"
157157
+ "FROM `scott`.`EMP`\n"
158158
+ "LIMIT 1";
@@ -179,7 +179,7 @@ public void testMvindexRangePositive() {
179179
verifyResult(root, expectedResult);
180180

181181
String expectedSparkSql =
182-
"SELECT ARRAY_SLICE(`array`(1, 2, 3, 4, 5), 1, 3 - 1 + 1) `result`\n"
182+
"SELECT ARRAY_SLICE(ARRAY(1, 2, 3, 4, 5), 1, 3 - 1 + 1) `result`\n"
183183
+ "FROM `scott`.`EMP`\n"
184184
+ "LIMIT 1";
185185
verifyPPLToSparkSQL(root, expectedSparkSql);
@@ -207,8 +207,8 @@ public void testMvindexRangeNegative() {
207207
verifyResult(root, expectedResult);
208208

209209
String expectedSparkSql =
210-
"SELECT ARRAY_SLICE(`array`(1, 2, 3, 4, 5), ARRAY_LENGTH(`array`(1, 2, 3, 4, 5)) + -3,"
211-
+ " ARRAY_LENGTH(`array`(1, 2, 3, 4, 5)) + -1 - (ARRAY_LENGTH(`array`(1, 2, 3, 4, 5))"
210+
"SELECT ARRAY_SLICE(ARRAY(1, 2, 3, 4, 5), ARRAY_LENGTH(ARRAY(1, 2, 3, 4, 5)) + -3,"
211+
+ " ARRAY_LENGTH(ARRAY(1, 2, 3, 4, 5)) + -1 - (ARRAY_LENGTH(ARRAY(1, 2, 3, 4, 5))"
212212
+ " + -3) + 1) `result`\n"
213213
+ "FROM `scott`.`EMP`\n"
214214
+ "LIMIT 1";

0 commit comments

Comments
 (0)