Uploaded image for project: 'phpBB3'
  1. phpBB3
  2. PHPBB3-11188

postgres search result count does not get the total count

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 3.1.0-dev
    • 3.1.0-a1
    • Search
    • None

    Description

      // if the total result count is not cached yet, retrieve it from the db
      if (!$result_count)
      {
      $result_count = sizeof ($id_ary);
      This doesn't take into account the results that are outside the Limit and offset of the query.
      Mysql uses FOUND_ROWS() function instead of sizeof($id_ary). Since pgsql doesn't have FOUND_ROWS, only possible solution is to use a COUNT function to calculate the total result count so that it can be cached.

      Attachments

        Activity

          People

            Oleg Oleg [X] (Inactive)
            dhruv.goel92 Dhruv Goel [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: