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] Where Join NOT working

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Where Join NOT working
 Login/Join
 
Platinum Member
posted
Can someone help with this? I am trying to use this
JOIN  LEFT_OUTER FILE SMRSD01 AT SMRSD01 TAG DQ TO MULTIPLE
FILE SUDBA17_VAR_VW AT SUDBA17_VAR_VW TAG DE AS JA1
WHERE DQ.PAACCT_CODE EQ DE.DLR_DEALER_CODE_C;
WHERE DQ.DDLRX_DLR_SUB_C EQ DE.DLR_DEALER_SUBCD_C;
WHERE DQ.COUNTRY_ISO3_C EQ DE.CUS_COUNTRY_ISO3_C;
END


I created this by following the IBI documentation. I am trying to do this in the fex because once I am done the values that I will be looking for will be dynamic.

I am doing this in both 7.6.7 and 7.6.9 the data is on Teradata 10i in both cases.

Thanks

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


dksib
DC Tech Services Inc
WF 8.2.1M
 
Posts: 117 | Location: US | Registered: February 09, 2004Report This Post
Expert
posted Hide Post
You haven't told us what's going wrong with your code.

Have you tried turning SQL traces on to see if the WebFOCUS code translates to SQL like you expect it to. You may have to include a special command to turn Left Outer Joins on, I know I have to for DB2.

This message has been edited. Last edited by: Francis Mariani,


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
The syntax is very restrictive for a conditional join. Double and triple-check the documentation to make sure that you have it coded correctly. It is not very forgiving.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
<dksib>
posted
Sorry,
it gives me
(FOC370) THE FIELDNAME USED IN JOIN CANNOT BE FOUND IN THE FILE: SMRSD01

These fields for both tables are the primary keys for thier respective tables.

I have set these also:
SET MULTIPATH=COMPOUND
SET ALL=ON
SET KEEPDEFINES=ON
 
Report This Post
Expert
posted Hide Post
JOIN  LEFT_OUTER FILE SMRSD01 AT SMRSD01 TAG DQ TO MULTIPLE


The "AT" entity should be a column name, not the table name (SMRSD01).

quote:
The syntax of the conditional (WHERE-based) JOIN command is

JOIN [LEFT_OUTER|INNER] FILE hostfile AT hfld1 [TAG tag1]
[WITH hfld2]
TO {UNIQUE|MULTIPLE}
FILE crfile AT crfld [TAG tag2] [AS joinname]
[WHERE expression1;
[WHERE expression2;
...]
END
where:

INNER
Specifies an inner join. If you do not specify the type of join in the JOIN command, the ALL parameter setting determines the type of join to perform.

LEFT_OUTER
Specifies a left outer join. If you do not specify the type of join in the JOIN command, the ALL parameter setting determines the type of join to perform.

hostfile
Is the host Master File.

AT
Links the correct parent segment or host to the correct child or cross-referenced segment. The field values used as the AT parameter are not used to cause the link. They are simply used as segment references.

hfld1
Is the field name in the host Master File whose segment will be joined to the cross-referenced data source. The field name must be at the lowest level segment in its data source that is referenced.

tag1
Is the optional tag name that is used as a unique qualifier for fields and aliases in the host data source.

hfld2
Is a data source field with which to associate a DEFINE-based conditional JOIN. For a DEFINE-based conditional join, the KEEPDEFINES setting must be ON, and you must create the virtual fields before issuing the JOIN command.

MULTIPLE
Specifies a one-to-many relationship between from_file and to_file. Note that ALL is a synonym for MULTIPLE.

UNIQUE
Specifies a one-to-one relationship between from_file and to_file. Note that ONE is a synonym for UNIQUE.

Note: Unique returns only one instance and, if there is no matching instance in the cross-referenced file, it supplies default values (blank for alphanumeric fields and zero for numeric fields).

crfile
Is the cross-referenced Master File.

crfld
Is the join field name in the cross-referenced Master File. It can be any field in the segment.

tag2
Is the optional tag name that is used as a unique qualifier for fields and aliases in the cross-referenced data source.

joinname
Is the name associated with the joined structure.

expression1, expression2
Are any expressions that are acceptable in a DEFINE FILE command. All fields used in the expressions must lie on a single path.

  
  
  
  


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
Platinum Member
posted Hide Post
Thanks - Francis

I saw that after I posted but the join is still not working. Now within the Table file it is not recognizing fields from the Cross Reference file.

Thanks,

David


dksib
DC Tech Services Inc
WF 8.2.1M
 
Posts: 117 | Location: US | Registered: February 09, 2004Report This Post
Expert
posted Hide Post
If the TABLE FILE is not recognizing fields from the Cross Reference file, you are most likely getting errors for the JOIN...


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
Guru
posted Hide Post
David,

This could be caused by duplicate JOIN AS names in your report.

I got the same error today as yours. My situation is that in the compound pdf report, each of the components has its own joins and I used all the default JOIN AS names. Individually they ran OK but when running the whole fex, all of a sudden, fields became undefined. The error disappeared after renaming all the JOIN AS.

Hope this helps. or is it too late?

Hua

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


Developer Studio 7.6.11
AS400 - V5R4
HTML,PDF,XLS
 
Posts: 305 | Location: Winnipeg,MB | Registered: May 12, 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     [CLOSED] Where Join NOT working

Copyright © 1996-2020 Information Builders