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     [CLOSED] query generated picking up primary column unnecessarily

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] query generated picking up primary column unnecessarily
 Login/Join
 
Gold member
posted
Hi Friends,

I have a code in my webfocus environment which is supposed to pick distinct value of search field and display. But the query which is getting generated order the result set by primary column of the table which was mentioned no where in the code.
  
 DEFINE FILE SALE_IND
 ID/A10 = HIGH_NET_WORTH_IND;
 DESCR/A10 = HIGH_NET_WORTH_IND;
 SRCHDBFLD/A10 = UPCASE(10,HIGH_NET_WORTH_IND,SRCHDBFLD);
 SELFIELD/A255 = '<OPTION Value="' | ID || '">' | DESCR | '</OPTION>';
 END
 TABLE FILE SALE_IND
 SUM SELFIELD
 BY HIGH_NET_WORTH_IND NOPRINT
 WHERE HIGH_NET_WORTH_IND NE ' '
 WHERE HIGH_NET_WORTH_IND NE '_BLANK_'
 ON TABLE HOLD
 END


If I see the query on running this procedure, it includes the primary column of the table in query. See below

(FOC2590) AGGREGATION NOT DONE FOR THE FOLLOWING REASON:
(FOC2597) USE OF DEFINE FIELD THAT CANNOT BE AGGREGATED : SELFIELD
SELECT T1."SALE_IND_ID",T1."HIGH_NET_WORTH_IND" FROM SALE_IND
T1 WHERE (T1."HIGH_NET_WORTH_IND" <> '_BLANK_') AND
(T1."HIGH_NET_WORTH_IND" <> ' ') ORDER BY T1."SALE_IND_ID";
0 NUMBER OF RECORDS IN TABLE= 119382 LINES= 4

The problem is the selection window taking minutes to fetch these values and the performance looks very poor.

Can anybody suggest why this happens?

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
quote:
(FOC2597) USE OF DEFINE FIELD THAT CANNOT BE AGGREGATED : SELFIELD


The message is clear as to explaining that you cannot SUM the SELFIELD column as it is unknown to the database (it is a virtual field in WebFOCUS).

In such cases, WebFOCUS needs to retrieve detail records from the database (which could be many depending on your filters) and will attempt to do the aggregation locally which usually shows poor performance as you have noticed.

Try something like this to see if it makes a difference:

TABLE FILE SALE_IND
SUM
COMPUTE SELFIELD/A255 = '<option value="> || MAX.HIGH_NET_WORTH_IND || ">' || MAX.HIGH_NET_WORTH_IND || '</option>';
BY HIGH_NET_WORTH_IND
WHERE HIGH_NET_WORTH_IND NE ' '
WHERE HIGH_NET_WORTH_IND NE '_BLANK_'
ON TABLE HOLD
END


Obviously I don't know your data but do you really have ' ' and '_BLANK_' as possible values in your database? or are you perhaps trying to retrieve any records where that field is NOT NULL?

If the latter applies, you may try this condition:

WHERE HIGH_NET_WORTH_IND NE MISSING


Hope that helps!

- Neftali.



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
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] query generated picking up primary column unnecessarily

Copyright © 1996-2020 Information Builders