Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] uppercase function not translated to Oracle upper

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] uppercase function not translated to Oracle upper
 Login/Join
 
Gold member
posted
Hi all,

I am facing a big performance issue with one of my report. this is because of one of the filter applied in the report which doesn't get translated to SQL and the query takes a very long time. The where statement is
WHERE UPCASE(100, CONSOLIDATED_GROUP, 'A100') CONTAINS 'ING'

Ideally, we were hoping this to be translated into
where upper(consolidated_group) like '%ING%' but it's not happening.

Can somebody please suggest me any other way of writing the same so that my query get translated into SQL perfectly.

PS: In my procedure, I do not flexibility to write SQL directly as it contains hundreds of dialog manager commands.

Regards,
Chirag

This message has been edited. Last edited by: Kerry,


7.6.11
Linux
Excel, HTML, PDF

 
Posts: 69 | Registered: February 15, 2008Report This Post
Virtuoso
posted Hide Post
First things first!
Is yours an Oracle database? If so, do you have a function-based index on UPPER(CONSOLIDATED_GROUP)? If not, I wouldn't see any big performance improvements.

To answer your question, I don't think UPCASE gets converted to UPPER when using a specific iWay Database Adapter. You may want to look for some documentation on the iWay Adapter for your particular database to see exactly what optimization techniques can be used (take a look at IBI's technical support web site). I can see 2 or 3 ways to achieve what want:

1. Create a database view on top of the table you want to query, including a field with the UPPER conversion there. Then create a WebFOCUS synonym on that view and use that one when producing your report.

2. You can also use SQL passthru to run actual SQL against your database structures. You can then use UPPER and any other specific functions your database supports.

3. If your database is Oracle 11g, you can also research about "virtual columns".

You may also want to update you signature to specify which database(s) you're targeting in your reporting environment.



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Virtuoso
posted Hide Post
Would this solve the problem? Or does CONSOLIDATED_GROUP contain mixed case values?

WHERE (CONSOLIDATED_GROUP CONTAINS 'ING')
   OR (CONSOLIDATED_GROUP CONTAINS 'ing');


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Gold member
posted Hide Post
Yes Dan, It may have mixed case values as well. I am researching on njsden solution.

Thanks,
Chirag


7.6.11
Linux
Excel, HTML, PDF

 
Posts: 69 | Registered: February 15, 2008Report This Post
Gold member
posted Hide Post
njsden solution worked for me. thanks everyone for their valuable suggestion.


7.6.11
Linux
Excel, HTML, PDF

 
Posts: 69 | Registered: February 15, 2008Report This Post
Virtuoso
posted Hide Post
If you are using Oracle 10g release 2 or later, there is another option. You can make your queries case-insensitive by using two Oracle session settings (both are necessary) available beginning with 10g R2. These settings will allow a simple CONTAINS/EQ comparison to be translated and passed to Oracle, thereby avoiding the performance degradation associated with use of WebFOCUS case-modifying functions.

SQL SQLORA
ALTER SESSION SET NLS_COMP=LINGUISTIC ;
END
-*
SQL SQLORA
ALTER SESSION SET NLS_SORT=BINARY_CI ;
END
-*
TABLEF FILE <filename>
PRINT/SUM <columns>
WHERE CONSOLIDATED_GROUP CONTAINS 'ING';
END


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] uppercase function not translated to Oracle upper

Copyright © 1996-2020 Information Builders