Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,367,994
Community Members
 
Community Events
168
Community Groups

IQL query displays wrong result

Hello,

my customer is looking for tickets that were created or modified in the last 7 days in the specified object types, but were not modified by user "Test_1".

We used the following query:

(Created > now(-7d) or Updated > now(-7d)) and objectType in
(object_1, object_2, object_3, object_4, ...) AND updatedBy (Test_1) order by Name desc

Unfortunately, the query leads to an incorrect result. What is wrong with the query or have I not taken into account?

As a JQL query it works.

I appreciate your help.

Thanks Heike

 

2 answers

0 votes
Charlie Misonne Community Leader Aug 23, 2022

Hi Heike,

You are trying this as an IQL query in Jira Insight is that right?

I don't think updatedBy() is valid and if it was you would neet a NOT clause because you  need the items that where not modified by that user.

Are you on Cloud or server/DC?

And what do you get as a result?

Hi @Charlie Misonne ,

yes my customer trying this IQL query in Jira Insight.

The result also shows the tickets changed by the user "Test_1".
I already suspected that something is wrong with the query. Unfortunately I don't know exactly how to include the NOT clause.

I`m waiting for a response from my client so I can let you know if they are using Jira Cloud or Data Center.

Once I have the info, I will get back to you.

Thanks and kind regards

Heike

Hi @Charlie Misonne  and @Alex Koxaras,

my customer go back to me and gave me the information. He uses Jira Data Center with the version number 8.22.1 and Insight 3.1.3.

I hope this information help to finde a resolution.

Kind regards

Heike

0 votes
Alex Koxaras Community Leader Aug 23, 2022

Hi @Heike Neumann and welcome to the community,

What are the different results you are getting?

Hi, @Alex Koxaras

I have the answer in Charlies comment given. You can of course also answer me.

thanks Heike

Alex Koxaras Community Leader Aug 31, 2022

@Heike Neumann updatedBy() is a JQL function and not IQL function. Meaning that this would lead to an error, if your client is writing this on the IQL field.

And you can't include an IQL attribute like objecttype on a JQL. That yields an error.

Issues should be associated with an asset, an object type. How this association is made? You have to have certain custom insight object fields, which are associated with screens of a project(s).

Since your requirement is the following:

my customer is looking for tickets that were created or modified in the last 7 days in the specified object types, but were not modified by user "Test_1".

I would assume that you already have the above association I'm mentioning and I would use a JQL to get my issues (not an IQL):

(Created > now(-7d) or Updated > now(-7d)) and CF_xxxxx = InsightObjectAttribute
AND updatedBy (Test_1) order by Name desc

Something like the above. But since I don't know how your fields are setup, that's all I can provide you with.

Hi @Alex Koxaras

thanks for the tip with the query updated(). This was my mistake, there I accidentally came to the query options of JQL.

My customer would like to do the query with IQL. With JQL the query already works for him.

Alex Koxaras Community Leader Aug 31, 2022

But what exactly does he needs to query about? IQL will not bring issues, but assets. I can't really understand the need here.

(Created > now(-7d) or Updated > now(-7d)) and objectType in
(object_1, object_2, object_3, object_4, ...) )

The above will work. But it will bring you assets that are created or updated the last 7 days. There isn't a function to query the db on who modified these assets.

Hello @Alex Koxaras ,

thanks for your answer and information. I will communicate this to my customer.

Have a nice day and by

Heike

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events