-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Medium
-
Affects Version/s: 10.3.4, 10.3.5
-
Component/s: Assets - IQL and Object Search
-
5
-
Severity 2 - Major
-
14
Issue Summary
The asset custom field configured with AQL is failing to load objects. This asset custom field references the selected value from the associated select list custom field. When AQL debugging is enabled, the logs reveal that AQL is not functioning correctly, resulting in the following error: com.riadalabs.jira.plugins.insight.common.exception.IQLValidationException: IQLValidationException: No matching attribute for AQL clause.
Steps to Reproduce
Scenario1
- Create a schema and define two object types, namely Students and Departments. Within the Students object type, create an attribute titled Student ID, which should be of the Default type with a Type value of Text.

- In the Department object type, create an attribute named "Department ID" with a type of "Default" and a type value of "Text."

- Create multiple objects for both object types. Next, configure an Asset custom field to reference a Jira single list custom field. To do this, first create a Select List (single choice) custom field. Add the options "Students" and "Department." In this example, the name of the custom field created is "Select CF."

- Create Asset custom field and configure the AQL as follows.

- Add both custom field to create issue screen and attempt to create Jira issue.

The asset custom field, as illustrated above, fails to load any objects. In the single select custom field, "student" was selected, and according to the AQL used, it should display all objects except those where ("Student ID" NOT IN ("JMS")).
Expected Results
The expected outcome is that when students are chosen from the single-select custom field, the assets custom field will display all objects from the student object type where ("Student ID" NOT IN ("JMS")). Please refer to the screenshot below for the same setup as of 9.12.18.
Similarly When a department is selected in the single-select custom field, the asset custom field will display all objects from the department object type where ** ("Department ID" = "CVL").

Actual Results
The assets custom field is not displaying any objects. When enabling the AQL debugging, specifically using com.riadalabs.jira.plugins.insight.services.core.iql, the following errors are observed in the logs.

2025-04-30 10:06:36,666+0000 http-nio-8080-exec-16 url: /jsm/rest/insight/1.0/customfield/default/10503/objects; user: admin WARN admin 606x1758x1 zk33qu 172.29.219.115,172.50.0.3 /rest/insight/1.0/customfield/default/10503/objects [c.r.j.p.i.s.core.impl.CustomFieldServiceImpl] Custom field objects could not be found: customFieldConfigId: 10503 com.riadalabs.jira.plugins.insight.common.exception.IQLValidationException: IQLValidationException: No matching attribute for AQL clause ("Department ID" = CVL) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.getOtherPredicate(ObjectPredicateAQLVisitor.kt:345) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.getAttributesPredicate(ObjectPredicateAQLVisitor.kt:286) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.acceptTerminalClause(ObjectPredicateAQLVisitor.kt:164) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.acceptTerminalClause(ObjectPredicateAQLVisitor.kt:56) at com.riadalabs.jira.plugins.insight.services.core.iql.model.IQLClauseVisitor.acceptIQLClause(IQLClauseVisitor.java:28) at com.riadalabs.jira.plugins.insight.services.core.iql.model.IQLClauseVisitor.acceptPrecedenceClause(IQLClauseVisitor.java:67) at com.riadalabs.jira.plugins.insight.services.core.iql.model.IQLClauseVisitor.acceptIQLClause(IQLClauseVisitor.java:26) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.acceptOrClause(ObjectPredicateAQLVisitor.kt:128) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.acceptOrClause(ObjectPredicateAQLVisitor.kt:56) at com.riadalabs.jira.plugins.insight.services.core.iql.model.IQLClauseVisitor.acceptIQLClause(IQLClauseVisitor.java:20) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.acceptAndClause(ObjectPredicateAQLVisitor.kt:112) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.ObjectPredicateAQLVisitor.acceptAndClause(ObjectPredicateAQLVisitor.kt:56) at com.riadalabs.jira.plugins.insight.services.core.iql.model.IQLClauseVisitor.acceptIQLClause(IQLClauseVisitor.java:22) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.IQLManagerImpl.appendIQLBeansAndSchemaToFilter(IQLManagerImpl.java:406) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.IQLManagerImpl.toObjectFilter(IQLManagerImpl.java:285) at com.riadalabs.jira.plugins.insight.services.core.iql.impl.IQLManagerImpl.findObjects(IQLManagerImpl.java:238) at com.riadalabs.jira.plugins.insight.services.core.impl.CustomFieldServiceImpl.findObjectsByCustomFieldConnectBean(CustomFieldServiceImpl.java:370) at com.riadalabs.jira.plugins.insight.services.core.impl.CustomFieldServiceImpl.findObjectsByCustomFieldConfig(CustomFieldServiceImpl.java:164) at com.riadalabs.jira.plugins.insight.channel.web.api.rest.services.customfield.DefaultCustomFieldResource.findCustomFieldObjects(DefaultCustomFieldResource.java:460) at jdk.internal.reflect.GeneratedMethodAccessor1726.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:569) at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory.lambda$static$0(ResourceMethodInvocationHandlerFactory.java:52) at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:146) at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:189) at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:176) at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:93) at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:478) at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:400) at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:81) at org.glassfish.jersey.server.ServerRuntime$1.run
The issue here is that the student object type includes the attribute student id, while the department object type contains the attribute department id. When a student is selected in the single select custom field, the AQL encounters a problem because it cannot identify the department id attribute used in the AQL. This was not a concern in the previous versions.
Scenario 2
I have included this second scenario to illustrate the bug in a straightforward manner without any custom fields.
In the Students object type, please use the AQL provided below to conduct a search. As mentioned earlier, the Student object type does not include a Department ID.
objectType = Students AND ("Student ID" NOT IN ("JMS")) OR ("Department ID" = CVL)
In Jira version 9.12.18, this AQL functions without any issues. However, in version 10.3.4, it fails and generates errors. I have attached both screenshots, as they illustrate the root of the problem.


Workaround
Currently there is no known workaround for this behavior. A workaround will be added here when available
- has a regression in
-
JSDSERVER-16397 AQL fails with Error: No matching attribute for AQL clause
-
- Closed
-
- is duplicated by
-
JSDSERVER-16178 Assets Post function "Assign Objects from an AQL query based on data from an issue" does not work when Assets CF includes a boolean attribute and an OR condition
-
- Closed
-
- links to