Uploaded image for project: 'mod-feesfines'
  1. mod-feesfines
  2. MODFEE-90

/feefineactions?query=cql.allrecords=1 sortby id&offset=10000&limit=10000 query on table with 126,079 rows results in empty result set

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: In bugfix review (View Workflow)
    • Priority: P3
    • Resolution: Done
    • Affects Version/s: 15.8.3
    • Fix Version/s: 15.9.0
    • Labels:
      None
    • Template:
    • Development Team:
      Vega

      Description

      When I execute query

      http://myhost:9130/feefineactions?query=cql.allrecords=1 sortby id&offset=10000&limit=10000
      

      against my system which has 126,070 rows in it, it results in the following response

      {\n  \"feefineactions\" : [ ],\n  \"totalRecords\" : 1000\n}
      

      The feesfines module log contains

      Jul 20, 2020 2:01:33 AM org.folio.cql2pgjson.CQL2PgJSON loadDbSchema
      INFO: loadDbSchema: Loaded templates/db_scripts/schema.json OK
      20 Jul 2020 02:01:33:138 INFO  CQLWrapper [501540164eqId] CQL >>> SQL: cql.allrecords=1 sortby id >>>WHERE true ORDER BY id LIMIT 10000 OFFSET 10000
      20 Jul 2020 02:01:33:166 INFO  LogUtil [501540192eqId] org.folio.rest.RestVerticle start  invoking getFeefineactions
      20 Jul 2020 02:01:33:167 INFO  LogUtil [501540193eqId] xxx.xxx.xxx.xxx:40528 GET /feefineactions query=cql.allrecords=1%20sortby%20id&offset=10000&limit=10000 HTTP_1_1 200 53 34 tid=diku OK
      

      I see

      2020-07-19 21:25:45.935 CDT [6744] diku_mod_feesfines@folio LOG:  statement: SELECT count_estimate_default('SELECT * FROM diku_mod_feesfines.feefineactions WHERE true ORDER BY id')
      

      in the SQL log. It's executing a query to get a count, but, never the query to get the data.

      Could the incorrect totalRecords value have something to do with it?

      Note, if I set offset to 0, I'm able to get the first 10,000 rows.

      I filed https://issues.folio.org/browse/MODPERMS-91 which I think may have the same problem.

        TestRail: Results

          Attachments

            Issue Links

              Activity

                People

                Assignee:
                jemiller Jon Miller
                Reporter:
                jemiller Jon Miller
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved:

                    TestRail: Runs

                      TestRail: Cases