vvysotskyi opened a new pull request #2420:
URL: https://github.com/apache/drill/pull/2420


   # [DRILL-8090](https://issues.apache.org/jira/browse/DRILL-8090): LIMIT 
clause is pushed down to an invalid OFFSET-FETCH clause for MS SQL Server
   
   ## Description
   - Updated Calcite fork version to include 
https://github.com/apache/calcite/commit/cc40a48cb8ca16f91bfdc66eaed6151805355d4b,
 so now regular limit can be pushed down to MS SQL as `TOP N` instead of 
`FETCH`.
   - Updated `JdbcLimitRule` and `JdbcSortRule` to prevent pushing down `FETCH` 
with `OFFSET` and without `ORDER BY`. 
   For such a case, some rules at the physical stage will generate a limit on 
top of the scan that includes `FETCH` only and another limit with `FETCH` and 
`OFFSET` above, so the limit will be pushed down.
   - Allowed matching JDBC rules for physical rel nodes.
   - Fixed issue with ClassCastException for Phoenix plugin (issue similar to 
DRILL-7972).
   
   ## Documentation
   NA
   
   ## Testing
   Checked manually.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to