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] Proble in MATCH

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Proble in MATCH
 Login/Join
 
Member
posted
Hi,

I'm trying using the below Focexec to Match Two files. One file contains information about patient and the other file conatins service charges that needs to be exclude. File file comes from a COBOL program. The record structure of COBOL file is:

01 OUT-FIELDS.
05 OUT-PT-NO PIC X(12) VALUE SPACES.
05 OUT-ATN-DR-NO-5 PIC 9(05) VALUE ZEROES.
05 OUT-ATN-DR-NO-1 PIC 9(01) VALUE ZERO.
05 OUT-REC-ID PIC X(01) VALUE SPACE.
05 OUT-ATN-DR-NAME PIC X(20) VALUE SPACES.
05 OUT-DTL-CHG-QTY PIC S9(04) VALUE ZEROES.
05 OUT-DTL-POST-MM PIC X(02) VALUE SPACES.

The fex is:
MATCH FILE RADP0094
SUM PT_NO
ATN_DR
REC_ID
ATN_DRNME
CHG_QTY
POST_DATE
DTL_SVCCD
DEPT_NO
PROC_MM
PROC_YY
BY DTL_SVCCD NOPRINT
BY PT_NO NOPRINT
BY ATN_DR NOPRINT
RUN
FILE SVCTABLE
SUM SVC_CODE
BY SVC_CODE NOPRINT
AFTER MATCH HOLD OLD-NOT-NEW
END

The Master file discription is:
FILE=RAD0094 ,SUFFIX=FIX
SEGNAME=RAD0094
FIELDNAME=PT_NO , ALIAS=PTNO , USAGE=A12 , ACTUAL=A12 ,
TITLE='PT NO',$
FIELDNAME=ATN_DR , ALIAS=ATNDR , USAGE=I6 , ACTUAL=A6 ,
TITLE='ATNDR',$
FIELDNAME=REC_ID , ALIAS=RECID , USAGE=A1 , ACTUAL=A1 ,
TITLE='RECID',$
FIELDNAME=ATN_DRNME , ALIAS=ATNDRNME , USAGE=A20 , ACTUAL=A20 ,
TITLE='ATNDRNME',$
FIELDNAME=CHG_QTY , ALIAS=CHGQTY , USAGE=I4 , ACTUAL=A04 ,
TITLE='CHGQTY',$
FIELDNAME=POST_DATE , ALIAS=POSTDATE , USAGE=A6 , ACTUAL=A06 ,
TITLE='POSTDATE',$
FIELDNAME=DTL_SVCCD , ALIAS=DTLSVCCD , USAGE=A7 , ACTUAL=A07 ,
TITLE='DTLSVCCD',$

While using the aboue FEX, I'm getting below error:

(FOC1346) : FORMAT ERROR: Record 1 , Column 39
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : CHG_QTY
(FOC1346) : FORMAT ERROR: Record 2 , Column 39
(FOC1130) FORMAT CONVERSION ERROR FIELD/KEY : CHG_QTY
(FOC1346) : FORMAT ERROR: Record 3 , Column 39

Please advice, what and where the problem is?

Thanks.

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


7.1.6
Win XP
HTML
 
Posts: 16 | Registered: February 29, 2008Report This Post
Member
posted Hide Post
quote:
RADP0094

quote:
SEGNAME=RAD0094


Manish,
In the MATCH command, you are using the file name as "RADP0094" and where as in the masterfiles Segment name the name is different i.e. "RAD0094" (P is missing). Could that be the problem? Can you correct this and give a try?


Version: WebFOCUS 7.6.6
O.S. WebFOCUS is mounted on Unix
Output Report: HTML, Excel, CSV, PDF and TXT
 
Posts: 14 | Registered: November 24, 2008Report This Post
Member
posted Hide Post
Harsha,

I changed the segment name in the master file and I'm still getting the same problem. So this would not be the problem.


7.1.6
Win XP
HTML
 
Posts: 16 | Registered: February 29, 2008Report This Post
Guru
posted Hide Post
I would look carefully at the specification in the MFD (synonym) for CHG_QTY - Actual is alpha and usage is INT? Why?


jimster06
DevStu WF 7.6.11
W7
HTML, PDF, EXL2K
 
Posts: 252 | Location: USA | Registered: April 15, 2003Report This Post
Member
posted Hide Post
Manish,
The error message means that the data starting in column 39 is in the wrong format.

The CHG_QTY field starts in column 39 so it is the field that is defined wrong.

Your MASTER is:
FIELDNAME=CHG_QTY , ALIAS=CHGQTY , USAGE=I4 , ACTUAL=A04 ,

Your COBOL description is:
05 OUT-DTL-CHG-QTY PIC S9(04) VALUE ZEROES.

An S9(04) will translate to:
Internal usage storage = 2 bytes
FOCUS Actual = I2
FOCUS Usage = I4

Try changing your MASTER and it should fix the problem.

You can find this documented in the mainframe FOCUS documentation under 'Field Format Conversion'.

Good Luck,
Michelle


WebFOCUS Production: UNIX 7.7.03M
WebFOCUS Test: UNIX EDASERVE 7.7.05 Client 8.0.01
 
Posts: 28 | Location: Connecticut USA | Registered: August 29, 2006Report This Post
Expert
posted Hide Post
According to the conversion chart that Michelle referenced, an S9(4) is a display numeric and there is a 1:1 relationship with the number displayed and the number of disk bytes used. The master format should be as follows:

FIELDNAME=CHG_QTY , ALIAS=CHGQTY , USAGE=P5, ACTUAL=Z04 ,
TITLE='CHGQTY',$ 


Note that the extra character in the USAGE is for the sign.


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
Master
posted Hide Post
quote:
05 OUT-PT-NO PIC X(12) VALUE SPACES.
05 OUT-ATN-DR-NO-5 PIC 9(05) VALUE ZEROES.
05 OUT-ATN-DR-NO-1 PIC 9(01) VALUE ZERO.
05 OUT-REC-ID PIC X(01) VALUE SPACE.
05 OUT-ATN-DR-NAME PIC X(20) VALUE SPACES.
05 OUT-DTL-CHG-QTY PIC S9(04) VALUE ZEROES.
05 OUT-DTL-POST-MM PIC X(02) VALUE SPACES.


You need to examine your COBOL WS compared to your MFD.
The above should convert to:
A12
P05
P01
A1
A20
P04
A2

FIELDNAME=DTL_SVCCD , ALIAS=DTLSVCCD , USAGE=A7 , ACTUAL=A07 ,
TITLE='DTLSVCCD',$

isn't even in the output that you have listed.


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
 
Posts: 755 | Location: TX | Registered: September 25, 2007Report This Post
Virtuoso
posted Hide Post
Once you get the MFD right ...

In order to merge properly, you have to make the match-key fieldnames in the two legs identical.
-* changes and comments in l.c.
SUM PT_NO ... PROC_YY 
BY DTL_SVCCD as svc_code
BY PT_NO NOPRINT 
BY ATN_DR NOPRINT 
RUN 
FILE SVCTABLE 
SUM SVC_CODE noprint (it will be null anyway for old-not-new)
BY SVC_CODE 
AFTER MATCH HOLD OLD-NOT-NEW 
END

This message has been edited. Last edited by: j.gross,


- Jack Gross
WF through 8.1.05
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Member
posted Hide Post
Hi Ginny,

I change the declaration of CHG_QTY and execute FEX. It works in the focus. And when I used this file in other COBOL program, I got SOC7 at below step.

ADD WS-IN-DTL-CHG-QTY TO WS-OUT-DOC-YTD-PTS-CUR

I read the above file in another program where CHG-QTY is defined as:
05 WS-IN-DTL-CHG-QTY PIC S9(04).

The declaration for WS-OUT-DOC-YTD-PTS-CUR and WS-IN-DTL-CHG-QTY is:
05 WS-OUT-DOC-YTD-PTS-CUR PIC S9(05) VALUE ZERO COMP-3.

My new MFD is:
FILE=RADP0094 ,SUFFIX=FIX
SEGNAME=RADP0094
FIELDNAME=PT_NO , ALIAS=PTNO , USAGE=A12 , ACTUAL=A12 ,
TITLE='PT NO',$
FIELDNAME=ATN_DR , ALIAS=ATNDR , USAGE=I6 , ACTUAL=A6 ,
TITLE='ATNDR',$
FIELDNAME=REC_ID , ALIAS=RECID , USAGE=A1 , ACTUAL=A1 ,
TITLE='RECID',$
FIELDNAME=ATN_DRNME , ALIAS=ATNDRNME , USAGE=A20 , ACTUAL=A20 ,
TITLE='ATNDRNME',$
FIELDNAME=CHG_QTY , ALIAS=CHGQTY , USAGE=P5 , ACTUAL=Z4 ,
TITLE='CHGQTY',$
FIELDNAME=POST_DATE , ALIAS=POSTDATE , USAGE=A6 , ACTUAL=A06 ,
TITLE='POSTDATE',$
FIELDNAME=DTL_SVCCD , ALIAS=DTLSVCCD , USAGE=A7 , ACTUAL=A07 ,
TITLE='DTLSVCCD',$

Please advise.


7.1.6
Win XP
HTML
 
Posts: 16 | Registered: February 29, 2008Report This Post
Member
posted Hide Post
Sorry....I made some wrong declarations. Now my job is completed successful and I'm going to review the results.

Thanks to all who helped me to solve this issue.


7.1.6
Win XP
HTML
 
Posts: 16 | Registered: February 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     [SOLVED] Proble in MATCH

Copyright © 1996-2020 Information Builders