Ph0en1x-re opened a new issue, #12729:
URL: https://github.com/apache/doris/issues/12729

   我们在其中字段上添加了布隆索引,查询条件只给一个条件只需要1秒就能查出来,但是只要添加上limit 1,查询都会非常慢,查询时间会到20多秒
   
   `  t0.COL1,
     t0.COL2,
     t0.RQ
     t0.COL3,
     t0.COL4
     date_format(t0.RQ,  '%Y-%m-%d  %H:%i:%s')  AS  CALCULATOR_2
   FROM  databasename.tablename  t0
   WHERE  (t0.COL1='123333')
     AND  (t0.COL4  LIKE  '1111%'
     AND  t0.RQ>=str_to_date('2022-08-21','%Y-%m-%d'))`
   下图是未加入limit的查询时间
   
![image](https://user-images.githubusercontent.com/56460308/190958918-66fe2a4b-9831-494b-b0ac-9486eab6fd41.png)
   
   
   `  t0.COL1,
     t0.COL2,
     t0.RQ
     t0.COL3,
     t0.COL4
     date_format(t0.RQ,  '%Y-%m-%d  %H:%i:%s')  AS  CALCULATOR_2
   FROM  databasename.tablename  t0
   WHERE  (t0.COL1='123333')
     AND  (t0.COL4  LIKE  '1111%'
     AND  t0.RQ>=str_to_date('2022-08-21','%Y-%m-%d'))
   limit 50`
   下图是加入limit的查询时间
   
![image](https://user-images.githubusercontent.com/56460308/190958842-cfd68055-1785-4c60-8eed-2cf4daa7b079.png)
   


-- 
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