Skip to content
  • Tor Didriksen's avatar
    fcff3f9d
    Bug#68458 Wrong count from FOUND_ROWS() on MySQL 5.6 · fcff3f9d
    Tor Didriksen authored
    Bug#16383173 WRONG COUNT FROM FOUND_ROWS() ON MYSQL 5.6
    
    The handling of SQL_CALC_FOUND_ROWS in combination with
    "order by with limit" was not specific enough,
    and could lead to wrong results for FOUND_ROWS() 
    
    The bug was that we took 'limit_found_rows' from filesort()
    for cases where filesort() did not produce the final result.
    
    Solution: let filesort() tell the execution machinery
    that a priority queue was in fact used to filter the result.
    fcff3f9d
    Bug#68458 Wrong count from FOUND_ROWS() on MySQL 5.6
    Tor Didriksen authored
    Bug#16383173 WRONG COUNT FROM FOUND_ROWS() ON MYSQL 5.6
    
    The handling of SQL_CALC_FOUND_ROWS in combination with
    "order by with limit" was not specific enough,
    and could lead to wrong results for FOUND_ROWS() 
    
    The bug was that we took 'limit_found_rows' from filesort()
    for cases where filesort() did not produce the final result.
    
    Solution: let filesort() tell the execution machinery
    that a priority queue was in fact used to filter the result.
Loading