Skip to content

Commit

Permalink
Change the description
Browse files Browse the repository at this point in the history
  • Loading branch information
LakeShen committed Sep 17, 2023
1 parent 1fa9d4b commit 0a4ecd8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@
* <blockquote><pre>{@code
* select max(totalprice) from orders}
* </pre></blockquote>
*
* @see CoreRules#REMOVE_REDUNDANT_SORT
*/
@Value.Enclosing
public class RemoveRedundantSort
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1216,7 +1216,8 @@ private void checkSemiOrAntiJoinProjectTranspose(JoinRelType type) {

/** Test case for
* <a href="https://issues.apache.org/jira/browse/CALCITE-5994">[CALCITE-5994]
* When a sort's input max row cnt is 1,remove the redundant sort</a>. */
* Add the optimize for removing the redundant order by when
* its source row number is less than or equal 1</a>. */
@Test void testSortRemoveWhenAggregateMaxRowCntIsOne() {
final String sql = "select count(*) as c\n"
+ "from sales.emp order by c";
Expand All @@ -1227,7 +1228,8 @@ private void checkSemiOrAntiJoinProjectTranspose(JoinRelType type) {

/** Test case for
* <a href="https://issues.apache.org/jira/browse/CALCITE-5994">[CALCITE-5994]
* When a sort's input max row cnt is 1,remove the redundant sort</a>. */
* Add the optimize for removing the redundant order by when
* its source row number is less than or equal 1</a>. */
@Test void testSortRemoveWhenLimitMaxRowCntIsOne() {
final String sql = "select *\n"
+ "from (select * from sales.emp limit 1)\n"
Expand Down

0 comments on commit 0a4ecd8

Please sign in to comment.