Uploaded image for project: 'Jira Cloud'
  1. Jira Cloud
  2. JRACLOUD-74624

the JQL worklogDate parameter search filter results are incorrect while using it in combination with NOT operator.

    XMLWordPrintable

Details

    Description

      Summary
      the JQL worklogDate parameter search filter results are incorrect while using it in combination with NOT operator.

      Steps to Reproduce
      From the Jira Issue Search Advanced Mode launch the following query as examples:

      Example 1:

      not worklogdate > "YYYY/MM/DD" and issue = <YOUR_ISSUE_KEY> 
      

       Example 2:

      not worklogdate > startofday(-10) and issue = <YOUR_ISSUE_KEY>
      

      Furthermore if we launch the following example query on a test instance:

      not worklogdate > "2019/05/15" and issue = TEST-299
      

      The issue TEST-299 which has his last worklog added on 15/Jun/19 is instead retrieved:

      Expected Results
      The expected results would be issues where the the worklog entries date are not > of "YYYY/MM/DD" or not > startofday(-10).

      Actual Results
      The actual results seems like the operator worklogdate is not working when using NOT in front of it: instead of looking for issues which don't have any work logged after a certain date, it is looking for issues for which the first logged date did not occur after a certain date. So basically, instead of looking into any work log in an issue, it is looking for the 1st work log entry which is incorrect.

      Workaround

      There is a workaround to fix the which consists in avoiding using NOT with the worklogdate operator, but to use an intermediate filter instead:

      1. First create a filter with the following JQL query:
        worklogdate > startofday(-5)
        
      2. Then run the following query by replacing FILTER_ID with the ID of the filter created in the previous step:
        filter != FILTER_ID 
        

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              tmarchionni@atlassian.com Tiziana Marchionni
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: