Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-20846

AQL searches with an unquoted number fail

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: AQL
    • Labels:
      None
    • Severity:
      Low

      Description

      Symptoms: Changing the order of the same AQL search terms causes the search to fail.

      Working AQL:

      items.find({"repo": "test-repo", "type": "folder", "created":

      {"$before": "1d"}

      , "depth": 3})

      Failing AQL:

      items.find({"repo": "test-repo", "type": "folder", "depth": 3, "created": {"$before": "1d"}})

      Running the Failing AQL causes Artifactory to return an error message:

      2019-12-12 00:26:34,639 [http-nio-8081-exec-5] [ERROR] (o.a.r.r.a.AqlResource:104) - Fail to execute query: items.find({"repo": "test-repo", "type": "folder", "depth": 3, "created": {"$before": "1d"}}).include("name", "created", "repo", "path", "modified_by")

       

      The "depth" term uses a number as a variable. I believe Artifactory is attempting to parse each term. Without quotes, the number is not read properly.

      If the number is surrounded by quotes it can be used anywhere. If the number is the last search term, it runs normally as the last term is a single character.

       

        Attachments

          Activity

              People

              Assignee:
              Unassigned
              Reporter:
              patrickr Patrick Russell
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:

                  Sync Status

                  Connection: RTFACT Sync
                  RTMID-20846 -
                  SYNCHRONIZED
                  • Last Sync Date: