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     Maintain data source stacks / identically named fields in different segments

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Maintain data source stacks / identically named fields in different segments
 Login/Join
 
Gold member
posted
I searched the forums and looked through the 7.6.1 Maintain manuals but couldn't find anything that confirms if Maintain data source stacks can't contain identically named fields from different segments in a master.

For example, I have a master "jobs".

FILENAME=ELEMENTS, SUFFIX=FOC     , $
  SEGMENT=JOB, SEGTYPE=S1, $
    FIELDNAME=NAME, USAGE=A8,
      TITLE='Job Name', $
    FIELDNAME=FREQ, USAGE=A1,
      TITLE='Job Freq', $
    FIELDNAME=DESC, USAGE=A150V,
      TITLE='Job Description', $
  SEGMENT=FILE, SEGTYPE=S1, PARENT=JOB, $
    FIELDNAME=NAME, USAGE=A36V,
      TITLE='File Name', $
    FIELDNAME=DESC, USAGE=A150V,
      TITLE='File Description', $


In the MDE I use the Stack Editor to create a new data source stack named stkFiles. I select the NAME field in the FILE segment. This puts the NAME field from the JOB segment plus NAME and DESC from the FILE segment into the right hand window and this looks correct. I also see the command that will be generated:
Infer elements.FILE.NAME into stkFiles;


When I click OK, though, the command that's put into my Maintain procedure is:
Infer elements.JOB.NAME into stkFiles;


It seems that Maintain is getting confused because of the identically named fields in the 2 different segments.

I've also just tried entering the Infer statement manually as:

infer elements.JOB.NAME elements.FILE.NAME into stkFiles;


When I look at stkFiles in the Project Explorer I only see 3 fields, NAME, DESC, and FREQ. So it seems that Maintain won't see the other NAME and DESC fields in the FILE segment.

I'm just wondering if someone can verify that what I'm seeing here is true. I guess I'll have to make sure all my fields in this master have unique names no matter if they're in different segments.

Thanks!


FOCUS 7.7.03
WebFOCUS 8.0.x/8.1
z/OS, Windows
 
Posts: 54 | Location: Everett, WA | Registered: September 27, 2005Report This Post
Gold member
posted Hide Post
Actually the master is named elements.


FOCUS 7.7.03
WebFOCUS 8.0.x/8.1
z/OS, Windows
 
Posts: 54 | Location: Everett, WA | Registered: September 27, 2005Report This Post
Master
posted Hide Post
When using Maintain, you do need to have unique field names in the Master.

The problem is when you load the data into a stack (or current area). If you have 2 fields with the same name in the same Master, Maintain cannot distinguish WHICH of the fields that you are referencing. The same problem occurs if you compute a field into a stack that already exists from either the database or a previous compute.

This problem won't occur when you have combined structures, since a stack can only reference on database.

Mark
 
Posts: 663 | Location: New York | Registered: May 08, 2003Report This Post
Expert
posted Hide Post
I think you have two solutions to this.

1. Change the Master to have different key fields.
2. Call a FEX, have the FEX rename the fields and return the table.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Member
posted Hide Post
Waz,

I just had the same problem. We had to put a filename qualifier in front of the field name.

Example :I had a few files fileA and fileB with the duplicate field name of AMOUNT.

If I needed to pick the second file amount, I would use:

fileB.AMOUNT.

Just keep qualifying the filename and it should work.


Dan McDonald
Version : 7.7.01
Platform:WindowsOutput : Excel, PDF, HTML
 
Posts: 15 | Location: Long Island | Registered: July 29, 2008Report 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     Maintain data source stacks / identically named fields in different segments

Copyright © 1996-2020 Information Builders