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.



Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] JOIN Issue
 Login/Join
 
Gold member
posted
Hi I am trying to JOIN 2 tables eg TABA and TABB.

But its only joining TABA fields with the first record of my TABB extract file.

JOIN STATE IN TABA TO ALL STATE IN TABB

TABLE FILE TABA
PRINT STATE SRC TAXG TAXT TAXA AMT
END

STATE SRC TAXG TAXT TAXA AMT
----- ---- ---- ---- ---- ---
NY A100 030 80 7 12.11
NY D100 - - - -
NY W500 - - - -
NY Z900 - - - -

Pleas help to resolve the issue.

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


WebFOCUS 7.6.13

Mainframe
all output (Report in mainframe)
 
Posts: 64 | Registered: February 24, 2010Report This Post
Member
posted Hide Post
Try using WHERE condition.

WHERE TABA.STATE EQ TABB.STATE

May be it will help


WebFOCUS 7.6.4, Mainframe Focus
Mainframe / Z/OS,MVS
Managed Reporting / Windows
All formats
 
Posts: 14 | Registered: July 26, 2011Report This Post
Expert
posted Hide Post
What is the source of the two tables ?

Are they from an RDBMS or FOCUS files, or Flat files ?


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
Virtuoso
posted Hide Post
Sounds like flat files, with only one NY record in the second (joined-to) file.

If it's a join to a FIX file, the result is correct for a one-to-many JOIN

In a one-to-many join to a flat file, if there were several matching records in the second file they would all be coupled to the first NY record in the first file, and for subsequent NY records in the first file the cupboard would be bare (since the process does not backspace the second file).

Procedurally, Focus reads forward in the second file, after the first match, until it encounters a non-NY keyed record. It then sits on that record waiting for a record in the first file that matches it.

So any additional NY records in the first file would show no match, whether the second file contains zero, one, or several records keyed to NY.

Bottom line: Remove "ALL" from the JOIN.


- Jack Gross
WF through 8.1.05
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Virtuoso
posted Hide Post
If these suggestions did not help, please post both master files. That way we can certainly help you better.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Gold member
posted Hide Post
TABA and TABB are not in the same sort order. They either need to both be sorted by STATE, or your TABB extract will need to have an index.

ON TABLE HOLD AS TABB FORMAT FOCUS INDEX STATE



Windows: WF 7.6.2: SQL Server 2008 R2
 
Posts: 86 | Location: Chicago | Registered: August 03, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic


Copyright © 1996-2020 Information Builders