Forums

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

Is it possible to write a JQL query that does not filter directly on a project?

Szatai Dávid March 17, 2023

Hi there 

Is it possible to write a JQL query that does not filter directly on a project but still lists the ticket types I am looking for?

That I tried and failed:

  • key = "ourproject" and updatedDate >= startOfDay(-30) and type in (Bug, Task)
  • alselect = ourprojectand updatedDate >= startOfDay(-30) and type in (Bug, Task)
  • project in ("ourprojectSupport") AND updatedDate/createdDate or created >= startOfDay(-30) AND type in (Bug, Task)-->this one contains 3 options 
    • updatedDate in our case it doesn't return the values we need because on our site we count tickets with resolved status and there can be tickets that are resolved for 2 months and then closed and this causes duplication 
  • text ~ "ourproject" AND created >= startOfDay(-30)

Currently using this but it is not adequate for what we need

project = ourproject AND created >= startOfDay(-30)

This request only came up because I would use the created vs resolved chart to create a trend, but if I filter directly on a project, when I open the resolved line it only lists the closed status tickets and the resolved status is not appering. (whereas the created line will include the resolved status)
For annual query not filtered by project it works correctly.

Anyone has an idea?

1 answer

1 accepted

0 votes
Answer accepted
Kristján Geir Mathiesen
Community Champion
March 17, 2023

Hi @Szatai Dávid 

I am not totally following, sorry. Have you tried:

resolution is not empty

to help find the tickets you need?

You can search by issue type like -> type in(Bug, Task) and that is independent of projects.

 

HTH,
KGM

Szatai Dávid March 20, 2023

Thank you for your reply
I have tried this in previous queries, but as the examples above show, it did not work as I would have expected.
The main problem is that I have this Chart that I want to use,Created tickets with resolved status , and on the resolved line it should show Closed status as a meaning , for this I need JQL.
And the dilemma is that the project wants to include resolved/closed status tickets in this line which doesn't work ,because it only shows the closed status on the resolved line ,BUT if there is no direct project filtering like
status in (Resolved, Closed) AND updatedDate >= startOfDay(-30) AND type in (Bug,Task)
AND created >= startOfDay(-30)
then both the resolved and closed status will appear in the resolved line.

 

And I'm looking for a way to filter for specific tickets so that the other projects don't show only the 1 project I'm interested in, but so far I haven't found one that works and unfortunately project = xyz doesn't work and the ones that do don't work:
type in (Bug, Task)
project in ("ourprojectSupport")
text ~ "ourproject"
key = "ourproject" and updatedDate >= startOfDay(-30) and type in (Bug, Task)
alselect = ourprojectand

 

 

2023-03-20_09h12_14.png

Kristján Geir Mathiesen
Community Champion
March 22, 2023

Sorry @Szatai Dávid I am stumped as well. I am guessing that you are trying to get more out of this chart than it can give. Maybe you need to look at other chart options (maybe even 3rd party app like this one).

HTH,
KGM

Like Szatai Dávid likes this
Szatai Dávid March 23, 2023

@Kristján Geir Mathiesen thank you for your help i will try it.

BR
David

Suggest an answer

Log in or Sign up to answer