ETEXT Template With SQL Function SUBSTR Not Working With A Negative Number (Doc ID 2140786.1)

Last updated on MAY 24, 2016

Applies to:

BI Publisher (formerly XML Publisher) - Version 12.2 to 12.2 [Release 12.2]
Information in this document applies to any platform.

Symptoms

ETEXT template with sql function SUBSTR not working with a negative number and need to truncate from the right instead of the left in the BIP desktop tool.

The problem can be reproduced with the following steps:
1. Fetch last 10 digits from right, we use the SQL function below:

select SUBSTR('80003007853',-10) from dual;

2. Result : 0003007853 (Correct), but in ETEXT template, the same function gives the first 10 digits from left which is incorrect:

SUBSTR('80003007853',-10)

The results: 8000300785 (are wrong).

Cause

Sign In with your My Oracle Support account

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

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms