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     Where's the off-switch for WF's "think-along" button?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Where's the off-switch for WF's "think-along" button?
 Login/Join
 
Virtuoso
posted
I can never find how to turn it off, but WF has a horrible horrible feature that automatically substitutes a field name that it can't find with another if it matches part of its name.

This time I used a field 'DIE' in a long list of DEFINE's and the results of the report were totally inexplicable. Turns out that the field 'DIE' wasn't defined at that point yet and that it got substituted for some other field - I haven't figured out which one yet...

Is there some way to automatically find which reports (accidentally!) depend on this "feature" so that we can fix them and turn it off globally without breaking a bunch of random reports for our users?

Finally, I think I asked this before and probably got an answer, but I can't find it. How do we turn that feature off?


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report This Post
Expert
posted Hide Post
1) Is "DIE" the "Shortest Unique Truncation" of another field?
2) Why would you NOT use the complete field name (imho: one of the "Best Practices" used in applications development)

Thus, not a "horrible horrible feature". But, rather, a very handy feature, again: imho...




   In FOCUS Since 1983 ~ from FOCUS to WebFOCUS.
   Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206
 
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005Report This Post
Virtuoso
posted Hide Post
quote:
Originally posted by Doug:
1) Is "DIE" the "Shortest Unique Truncation" of another field?


Ah yes, that's what it's called. I can't seem to remember that.

Well yes, apparently. With as many fields, defines, computes and temporary hold files in that report though, that's not easy to figure out!

quote:
Originally posted by Doug:
2) Why would you NOT use the complete field name (imho: one of the "Best Practices" used in applications development)

Thus, not a "horrible horrible feature". But, rather, a very handy feature, again: imho...


Because if I type a field name that doesn't exist, I made a mistake. I rather know that I made a mistake (by having an error thrown in my face) than have it substituted for something else (likely wrong) behind my back. That is not convenient at all! It gives me a seemingly functioning procedure that reports incorrect data! Thankfully I had a way to verify the correctness for this particular case and it only took me a few hours to figure out why it was incorrect...

I do not quite understand how this could be a "best practice", unless handing people loaded shotguns barrel-down is considered a "best practice". Thanks a lot, but I rather keep my feet...

If this is considered a "best practice", I suppose there is no knob to turn it off?


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report This Post
Expert
posted Hide Post
SET FIELDNAME = NOTRUNC

I set this everywhere I go.


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Expert
posted Hide Post
FIELDNAME
The FIELDNAME parameter controls whether long and qualified field names are supported.

This command cannot be used with ON TABLE SET.

The syntax is:

SET FIELDNAME = {NEW|NOTRUNC|OLD}
where:

NEW
Supports long and qualified field names. NEW is the default value.

NOTRUNC
Supports long and qualified field names, but not unique truncations.

OLD
Limits field names to 12 characters. Qualified field names are not supported.


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Expert
posted Hide Post
Either way... Personal preferences I guess...

I would rather be fully explicit in the use of fieldnames. That way I will always get an error thrown in my face, which I'd rather have then the possibility of using incorrect fields (due to the "shortest unique truncated names").

Thanks to Francis for pointing out the "SET FIELDNAME". Now, it's up to us to use it or not.

Always Smilering
 
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005Report This Post
Virtuoso
posted Hide Post
Thanks Francis, just what I was looking for.

Doug, you're confusing me... At one point you appear to be defending shortest unique truncations and then you say you'd rather be fully explicit in the use of field-names...

My initial post was prompted by being fooled by "Shortest Unique Truncation" taking place on a field that was fully qualified but just happened to not be defined at that point yet.
An error would have been convenient, silent substitution by a field-name that WF thought I meant was not. Well, at least now I know how to turn that off...

Edit:
For an example of how harmful this feature can be, consider the following bit of code I found by setting FIELDNAME to NOTRUNC:
DEFINE TABLE XXX
	CYCLE_CNT2/I5	= IF DIE CONTAINS '999' THEN 0 ELSE CYCLE_CNT;
	CYCLE_CNT/I5	= 1;
END


The computation for CYCLE_CNT was moved to a later section of the procedure and the above line wasn't moved with it. As a result, "thanks" to shortest unique truncation, the field was conditionally evaluating to itself!

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


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report This Post
Expert
posted Hide Post
Sorry for any confusion ... I'm really not defending the Shortest Unique Truncation (SUT) just identifying it as the possible issue.

Consider this "CYCLE_CNT" looks to be the SUT for "CYCLE_CNT2". But, it's not. The reason being is that it is a complete field name in and of itself. On the other hand, "CYCLE_C" is a SUT of both CYCLE_CNT and CYCLE_CNT2. So, what field is it, CYCLE_CNT or CYCLE_CNT2? Thus my preference for the full name.

I hope this clears up some of that confusion. If not, what else can I say?
 
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005Report This Post
Virtuoso
posted Hide Post
quote:
Consider this "CYCLE_CNT" looks to be the SUT for "CYCLE_CNT2".


It was in our case, hence the posted example. I updated it with something closer resembling the actual situation Wink


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report 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     Where's the off-switch for WF's "think-along" button?

Copyright © 1996-2020 Information Builders