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     USE & FOR DYNAMIC JOIN - ERRORS - SOLVED

Read-Only Read-Only Topic
Go
Search
Notify
Tools
USE & FOR DYNAMIC JOIN - ERRORS - SOLVED
 Login/Join
 
Master
posted
I have created a dynamic join via dialogue manager.
In this code snippet I am joining these fields:

quote:

AGEGRP IN AGEGRP_99_A TO MULTIPLE AGEGRP IN AGEGRP_00_A

(USING FULLY QUALIFIED NAMES)...

quote:

-SET &JNX = 'JOIN' | ' ' | &CMPL_FN | '.' | &CMPL_FN | '.' | &FNA || ' IN ' | &CMPL_FN ;
-SET &JNY = ' TO MULTIPLE ' | &CMPL_FN_2 | '.' | &CMPL_FN_2 | '.' | &FNA || ' IN ' | &CMPL_FN_2 | ' TAG J0 AS J0' ;

-SET &JNZ = &JNX||&JNY ;


Then, to test it I have tried this:

quote:

-TYPE &JNZ.EVAL
-RUN

CHECK FILE &CMPL_FN (PICT
-RUN

?FF &CMPL_FN
-RUN
-EXIT


I am disappointed to get thei result:

CHECK FILE AGEGRP_99_A (PICT
-RUN

0 NUMBER OF ERRORS= 0
NUMBER OF SEGMENTS= 1 ( REAL= 1 VIRTUAL= 0 )
NUMBER OF FIELDS= 14 INDEXES= 0 FILES= 1
TOTAL LENGTH OF ALL FIELDS= 154
?FF AGEGRP_99_A
-RUN

FILENAME= AGEGRP_99_A
AGEGRP AGEGRP A50
_TYPE_ _TYPE_ D20.2
JUL98 JUL98 D20.2
AUG98 AUG98 D20.2
SEP98 SEP98 D20.2
OCT98 OCT98 D20.2
NOV98 NOV98 D20.2
DEC98 DEC98 D20.2
JAN99 JAN99 D20.2
FEB99 FEB99 D20.2
MAR99 MAR99 D20.2
APR99 APR99 D20.2
MAY99 MAY99 D20.2
JUN99 JUN99 D20.2

-EXIT

I anticipated that I would also see the fields which are contained in the AGEGRP_00_A file, but I did not....

Has anyone else had this problem? Frowner

Thanks!

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


Tomsweb
WebFOCUS 8.1.05M, 8.2.x
APP Studio, Developer Studio, InfoAssist, Dashboards, charts & reports
Apache Tomcat/8.0.36
 
Posts: 573 | Location: Baltimore, MD | Registered: July 06, 2006Report This Post
Virtuoso
posted Hide Post
In stead of -TYPE &JNZ.EVAL do a &JNZ.EVAL (without the -type in front of it).
I do see you building the join command, but I have not seen in your code that you actually execute the join command.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Master
posted Hide Post
Gamp,

Thank you. I did that and I do see fields from both of the files.

quote:

&JNZ.EVAL
-RUN

?FF &CMPL_FN
-RUN
-EXIT

FILENAME= AGEGRP_99_A
AGEGRP_99_A.AGEGRP AGEGRP_99_A.AGEGRP A50
AGEGRP_99_A._TYPE_ AGEGRP_99_A._TYPE_ D20.2
JUL98 JUL98 D20.2
AUG98 AUG98 D20.2
SEP98 SEP98 D20.2
OCT98 OCT98 D20.2
NOV98 NOV98 D20.2
DEC98 DEC98 D20.2
JAN99 JAN99 D20.2
FEB99 FEB99 D20.2
MAR99 MAR99 D20.2
APR99 APR99 D20.2
MAY99 MAY99 D20.2
JUN99 JUN99 D20.2
AGEGRP_00_A.AGEGRP AGEGRP_00_A.AGEGRP A50
AGEGRP_00_A._TYPE_ AGEGRP_00_A._TYPE_ D20.2
JUL99 JUL99 D20.2
AUG99 AUG99 D20.2
SEP99 SEP99 D20.2
OCT99 OCT99 D20.2
NOV99 NOV99 D20.2
DEC99 DEC99 D20.2
JAN00 JAN00 D20.2
FEB00 FEB00 D20.2
MAR00 MAR00 D20.2
APR00 APR00 D20.2
MAY00 MAY00 D20.2
JUN00 JUN00 D20.2


Now, I must determine how to print with only the sort fields from
the host file as my code below gives me the sort fields from both
files:

TABLE FILE &CMPL_FN
PRINT *
BY AGEGRP
BY _TYPE_ Roll Eyes
END
-RUN
[/QUOTE]

[QUOTE]
AGEGRP _TYPE_ AGEGRP _TYPE_ JUL98 AUG98
0-<1 1.00 0-<1 1.00 25,950.00 25,977.00
[QUOTE]

I can probably do something in a define. Roll Eyes

Thanks!


Tomsweb
WebFOCUS 8.1.05M, 8.2.x
APP Studio, Developer Studio, InfoAssist, Dashboards, charts & reports
Apache Tomcat/8.0.36
 
Posts: 573 | Location: Baltimore, MD | Registered: July 06, 2006Report This Post
Virtuoso
posted Hide Post
quote:
&CMPL_FN

Isn't that the name of your host file?
If so then you could do something similar as what you did for the join.
Something like this:
-SET &PART = 'BODY';
TABLE FILE CAR
PRINT
     &PART.EVAL.BODYTYPE
     &PART.EVAL.SEATS
     &PART.EVAL.DEALER_COST
     &PART.EVAL.RETAIL_COST
     &PART.EVAL.SALES
ON TABLE NOTOTAL
END


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Expert
posted Hide Post
Or
-SET &PART = 'BODY';
TABLE FILE CAR
PRINT
     &PART...BODYTYPE
     &PART...SEATS
     &PART...DEALER_COST
     &PART...RETAIL_COST
     &PART...SALES
ON TABLE NOTOTAL
END


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
Master
posted Hide Post
You mean like this:

quote:

TABLE FILE &CMPL_FN
PRINT
&CMPL_FN.EVAL.JAN99
&CMPL_FN.EVAL.FEB99
&CMPL_FN.EVAL.MAR99
&CMPL_FN.EVAL.APR99
&CMPL_FN.EVAL.MAY99
&CMPL_FN.EVAL.JUN99
&CMPL_FN.EVAL.JUL99
&CMPL_FN.EVAL.AUG99
&CMPL_FN.EVAL.SEP99
&CMPL_FN.EVAL.OCT99
&CMPL_FN.EVAL.NOV99
&CMPL_FN.EVAL.DEC99

BY &CMPL_FN.EVAL.AGEGRP
BY &CMPL_FN.EVAL._TYPE_
END
-RUN
-EXIT


That is very cool if all my fields are from the same file.
If not then I will have to change the value of &CMPL_FN
to retrieve data from the 2nd (xref) file.

I apologize if I did not state what may be obvious...I am
trying to print a calendar year report as the table I am
forced to report from contains only a Fiscal Year of data.

Sorry!

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


Tomsweb
WebFOCUS 8.1.05M, 8.2.x
APP Studio, Developer Studio, InfoAssist, Dashboards, charts & reports
Apache Tomcat/8.0.36
 
Posts: 573 | Location: Baltimore, MD | Registered: July 06, 2006Report This Post
Expert
posted Hide Post
Check the syntax of "CHECK FILE" ... no need for the left paren in 'CHECK FILE AGEGRP_99_A (PICT", is there?...
 
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005Report This Post
Master
posted Hide Post
In my post yesterday, I used the CHECK FILE command incorrectly:

quote:

CHECK FILE AGEGRP_99_A (PICT
-RUN

(FOC1517) UNRECOGNIZED COMMAND CHEC
0 NUMBER OF ERRORS= 0
NUMBER OF SEGMENTS= 2 ( REAL= 1 VIRTUAL= 1 )
NUMBER OF FIELDS= 28 INDEXES= 0 FILES= 2
TOTAL LENGTH OF ALL FIELDS= 308
-EXIT



The correct syntax of the command is captioned below:

quote:

CHECK FILE AGEGRP_99_A PICT
-RUN
0 NUMBER OF ERRORS= 0
NUMBER OF SEGMENTS= 2 ( REAL= 1 VIRTUAL= 1 )
NUMBER OF FIELDS= 28 INDEXES= 0 FILES= 2
TOTAL LENGTH OF ALL FIELDS= 308
1SECTION 01
STRUCTURE OF GNTINT FILE AGEGRP_9 ON 11/05/10 AT 09.45.40
AGEGRP_>
01 S0
**************
*AGEGRP **
*_TYPE_ **
*JUL98 **
*AUG98 **
* **
***************
**************
I
I
I
I AGEGRP_>
02 I KM
..............
:AGEGRP ::K
:_TYPE_ ::
:JUL99 ::
:AUG99 ::
: ::
:............::
.............:
JOINED AGEGRP_00_A
-EXIT



Tomsweb
WebFOCUS 8.1.05M, 8.2.x
APP Studio, Developer Studio, InfoAssist, Dashboards, charts & reports
Apache Tomcat/8.0.36
 
Posts: 573 | Location: Baltimore, MD | Registered: July 06, 2006Report This Post
Virtuoso
posted Hide Post
quote:
If not then I will have to change the value of &CMPL_FN to retrieve data from the 2nd (xref) file.

And that would then be in the &CMPL_FN_2 variable, wouldn't it?


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report 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     USE & FOR DYNAMIC JOIN - ERRORS - SOLVED

Copyright © 1996-2020 Information Builders