SeaSoonKeun opened a new issue, #21912:
URL: https://github.com/apache/doris/issues/21912

   ### Search before asking
   
   - [X] I had searched in the 
[issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no 
similar issues.
   
   
   ### Version
   
   2.0-beta (Latest)
   
   ### What's Wrong?
   
   when executing sql query to mysql by doris catalog, I find the response 
speed is much lower than the way to query in mysql client. At the same time, I 
also use the drill engine to execute the same sql, and the response speed is 3 
times faster than doris. 
   
   After that, I try to explain the sql query execute plan, I find some wrong 
in doris. |
   
   such as below :
   
   1.  
   
    ```SELECT COUNT(*) FROM `xx`.`dwd__df` ```
   
   explain:
   
       0:VJdbcScanNode                                                          
   |
       |      TABLE: `xx`.`dwd_xx_df`                         |
       |      QUERY: SELECT `ip_status` FROM `xx`.`dwd_xx_df` |
       
   ps: why does doris scan the concrete field in the table, rather than 
querying count(*) directly
   
   2.  
   ```
   SELECT
     *
   FROM
     `xx`.`dwd_xx_df`
   WHERE
     `id` IN(
       'xxx',
       'yyyy'
     )
     AND `dayid`='20230711'
   LIMIT
     20
   OFFSET
     326760
   ```
   
   explain:
   
   SELECT  FROM `xx`.`dwd_xx_df` WHERE (`resource_pool_id` IN ('xxx',  'yyyy')) 
AND (`dayid` = '20230711') LIMIT 326780
   
   ps: why does not  doris pick the OFFSET info, by oposite, it takes the wrong 
limit info . I am confused.
   
   
   
   ### What You Expected?
   
   fix the issue and improve the query speed of doris mysql catalog
   
   ### How to Reproduce?
   
   _No response_
   
   ### Anything Else?
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [X] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of 
Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
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: commits-unsubscr...@doris.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to