Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
10 replies
Subscribers
7 subscribers
Views
5569 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
AI and Rules
When running a query rule, got an unexpected error ExpressionRuntimeException$AppianExceptionProvider
Rahul Gundu
over 7 years ago
When running a query on expression editor i got below error. I went through forum, there is a article on date out of range error and i feel the below error might be different. Am also attaching application-server.log.
Error:
Expression evaluation error in rule 'mm_getprocessinstances' at function 'queryruleexec': Error evaluating function 'queryruleexec' : Unexpected error executing query (type: [INIMMVUIPROCESSINSTANCELOGDT99798], query: [MM_GetProcessInstances], order by: [[Sort['PRCS_INSTC_LOG_ID' asc]]], filters:[null]).
Thanks
Rahul Gundu
OriginalPostID-234579
application-server.log
Discussion posts and replies are publicly visible
0
Stefan Helzle
A Score Level 3
over 7 years ago
Your log file mentions a timeout:
Caused by: org.hibernate.JDBCException: This query did not finish within the timeout period: could not execute query
at
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Colton Beck
over 7 years ago
I agree with Stefan. This isn't a date range issue. Are you querying a slow-performing view, or not batching your query appropriately?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Rahul Gundu
over 7 years ago
@coltonb, Even i tried with batchSize:1. Still it giving the same error.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Colton Beck
over 7 years ago
Could you paste the query body into a comment? Are you querying a table or a view?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Rahul Gundu
over 7 years ago
Am using query rule not query entity, And am querying on a view. The view is working perfect in database.
Query rule is
rule!MM_GetProcessInstances(
a!pagingInfo(startIndex:1,batchSize:1)
)
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Colton Beck
over 7 years ago
Any chance there are 0000-00-00 dates in the view you're pulling from? If not, are there any issues in the data store mapping?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Bishnu Panigrahi
Appian Employee
over 7 years ago
The performance logs provide more information on the query's prepare, execute and transform durations. That can help you narrow down the bottleneck source. Also, the health check reports poor performing queries and gives the same breakdown in a more reader-friendly format.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Rahul Gundu
over 7 years ago
Even i tried to create a record for that view, still it gave an error.
Error
An error occurred while retrieving the data for “MM_PROCESS_INSTANCES”. (APNX-1-4205-003)
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Navajith K
over 7 years ago
@rahulg262, Do you have a column in view with unique data? For query rule to work, I believe we need a column with unique data.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
narasimhaadityac
A Score Level 2
over 7 years ago
Hi Rahul, I believe in case of Query Rules, generally even though you are giving the pagination information, first the query execution is done and then the pagination is done on the resultant set. in this case the query execution is not complete hence you are getting the error.
if we have a query entity, the pagination parameters are passed to the query execution and which will get you the exact count of rows you have provided in the pagination parameter.
I am suspecting same is the case with records as well, even though records are shown only the first 100, at the end it is displaying the standard verbiage like "Showing results 1 - 100 of 12,345" I think its loading the entire dataset before displaying it.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel