My Oracle Support Banner

Rules and Behaviors "java.lang.StringIndexOutOfBoundsException: String index out of range: -1" Error Saving Custom SQL Expression (Doc ID 2530881.1)

Last updated on JULY 26, 2023

Applies to:

Oracle Communications MetaSolv Solution - Version 6.3.0 and later
Information in this document applies to any platform.

Symptoms

MetaSolv Solution version 6.3.0.772

Attempting to change or update the Custom SQL Expression for a Rules and Behavior in the GUI throws a "java.lang.StringIndexOutOfBoundsException: String index out of range: -1" error on the Rules and Behaviors > Rule Summary > Expression page and there is no way to save the changes.

Error Text

Image of Error in GUI


Recreation Steps

1. Application Setup

2. Work Management Setup

3. Rules and Behaviors

4. Click an existing Rules and Behaviors

5. . Click the Edit link for the Expression section

6. Select the Custom SQL check-box and enter the SQL string below

    SELECT COUNT(*) FROM SERV_REQ WHERE DOCUMENT_NUMBER = ?

7. Click Save and Close and the StringIndexOutOfBoundsException is thrown

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.