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     [SOLVED] Problems using MERGE

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Problems using MERGE
 Login/Join
 
Member
posted
I'm trying to create a merged data set as follows:

Concatenate table A with table B
Concatenate table C with table D
then join concatenated A/B to concatenated C/D

I used the code documented in wf77crlang.pdf, page 857 and I have mocked up
similar code using the car file (below).

However, the result set contains 0 rows using my own data and when using the sample CAR
file.

(0 NUMBER OF RECORDS IN TABLE= 0 LINES= 0)

-SET &ECHO = ALL;
TABLE FILE CAR
SUM DEALER_COST
BY CAR
BY MODEL
WHERE COUNTRY EQ 'ENGLAND'
ON TABLE HOLD AS A
END
-RUN
TABLE FILE CAR
SUM DEALER_COST
BY CAR
BY MODEL
WHERE COUNTRY EQ 'ITALY'
ON TABLE HOLD AS B
END
-RUN
TABLE FILE CAR
SUM RETAIL_COST
BY CAR
BY MODEL
WHERE COUNTRY EQ 'ENGLAND'
ON TABLE HOLD AS C
END
-RUN
TABLE FILE CAR
SUM RETAIL_COST
BY CAR
BY MODEL
WHERE COUNTRY EQ 'ITALY'
ON TABLE HOLD AS D
END
-RUN
MATCH FILE A
SUM DEALER_COST
BY CAR
BY MODEL
MORE
FILE B
RUN
FILE C
SUM RETAIL_COST
BY CAR
BY MODEL
AFTER MATCH HOLD OLD-OR-NEW
MORE
FILE D
END
-RUN
TABLE FILE HOLD
PRINT *
END

This message has been edited. Last edited by: Kerry,
 
Posts: 29 | Registered: July 17, 2007Report This Post
Virtuoso
posted Hide Post
What's your release? -- On 7.6.9, when I run the code in your post I get 8 lines, no errors.
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Member
posted Hide Post
Server is 7.7.04, client is 7.7.03.
 
Posts: 29 | Registered: July 17, 2007Report This Post
Expert
posted Hide Post
Tim,

Put this at the top of the fex and re-run:

APP PREPENDPATH IBISAMP
-RUN


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Member
posted Hide Post
Thanks for the reply, but same result.
 
Posts: 29 | Registered: July 17, 2007Report This Post
Expert
posted Hide Post
Tim

At the top add:
-SET &ECHO=ALL;

Run the, program, right-click and view source. See if WF is generating an error...

Mr. Gross, don't mean to steal your thunder, works for me, also...


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Member
posted Hide Post
The following text appears immediately after the MATCH request END statement:

BYPASSING TO END OF COMMAND
TABLE FILE HOLD
PRINT *
END
0 NUMBER OF RECORDS IN TABLE= 0 LINES= 0
 
Posts: 29 | Registered: July 17, 2007Report This Post
Member
posted Hide Post
Thanks to all,

I have opened a ticket since this appears to be version related and they have forwarded to programming.
 
Posts: 29 | Registered: July 17, 2007Report This Post
Virtuoso
posted Hide Post
Tim-

My guess is that the use of MORE within MATCH is broken in your release.

Try this:

-SET &ECHO = ON;
TABLE FILE CAR  SUM DEALER_COST BY CAR BY MODEL WHERE COUNTRY EQ 'ENGLAND' ON TABLE HOLD AS A
END
-RUN
TABLE FILE CAR  SUM DEALER_COST BY CAR BY MODEL WHERE COUNTRY EQ 'ITALY' ON TABLE HOLD   AS B
END
-RUN
TABLE FILE CAR  SUM RETAIL_COST BY CAR BY MODEL WHERE COUNTRY EQ 'ENGLAND' ON TABLE HOLD AS C
END
-RUN
TABLE FILE CAR  SUM RETAIL_COST BY CAR BY MODEL WHERE COUNTRY EQ 'ITALY' ON TABLE HOLD   AS D
END
-RUN

TABLE FILE A
  SUM DEALER_COST BY CAR BY MODEL     ON TABLE HOLD AS AB
  MORE
  FILE B
END
TABLE FILE C
  SUM RETAIL_COST BY CAR BY MODEL     ON TABLE HOLD AS CD
  MORE
  FILE D
END
-RUN
MATCH FILE AB
  SUM DEALER_COST BY CAR BY MODEL
  RUN
FILE CD
  SUM RETAIL_COST BY CAR BY MODEL
  AFTER MATCH HOLD OLD-OR-NEW
END
-RUN

TABLE FILE HOLD
  PRINT *
END


- Jack Gross
WF through 8.1.05
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report 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     [SOLVED] Problems using MERGE

Copyright © 1996-2020 Information Builders