Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

The CREATED param in filter gives wrong result

Nguyen Tuan Trung
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 25, 2019

I was trying to filter all new tasks created last week

project = SRP AND issuetype in (Bug, "Change Request", Task) AND created >= 2019-08-19 AND created <= 2019-08-26 ORDER BY priority DESC, updated DESC

return a task with created = 2019-08-25

while

project = SRP AND issuetype in (Bug, "Change Request", Task) AND created >= 2019-08-19 AND created <= 2019-08-25 ORDER BY priority DESC, updated DESC

does not.

2 answers

1 accepted

0 votes
Answer accepted
DPKJ
Community Champion
August 25, 2019

This is because, “created” field is timestamp and it takes both date and time (yyyy-MM-dd HH:mm).

Now when you query for issues created <= 2019-08-25, it means 2019-08-25 00:00 (which is zero o’clock on 25th), but your issues were created after that so they are not part of result set.

There was an issue logged against this behaviour to Atlassian but they decided it to not fix to keep backward compatibility.

0 votes
Milan Chheda [INFOSYSTA]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 25, 2019

You can the use the below to get issues created last week:

project = SRP AND issuetype in (Bug, "Change Request", Task) AND created > startOfWeek(-1w) and created< startOfWeek() ORDER BY priority DESC, updated DESC

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events