IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Issues when handling with VB file


IBM Mainframe Forums -> CA Products
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
michaeltai
Warnings : 1

New User


Joined: 23 Jul 2005
Posts: 20

PostPosted: Wed Sep 03, 2008 3:07 pm
Reply with quote

Code:

 9/03/08  0.19.07                             CA-EASYTRIEVE PLUS-6.4 0202       
                                                 MATSON NAVIGATION CO           
PROGRAMS AND ALL SUPPORTING MATERIALS COPYRIGHT (C) 1982, 1996 BY COMPUTER ASSOC
    75 *******A006 PROGRAM INTERRUPT - CODE 7 (DATA EXCP)                       


Code:

SDSF OUTPUT DISPLAY $CMTAI8  JOB09364  DSID   102 LINE 0       COLUMNS 02- 81
COMMAND INPUT ===>                                            SCROLL ===> CSR
******************************** TOP OF DATA ********************************

                                                                             
    4 FILE KS400 VB (324 13682)                                             
    5   RECID                              1     8   A                       
    6   HDRIF                             14     3   A                       
    7   INPUT-REC                          1   324   A                       
                   
                                                                             
    9   BATCH-REC                          W   324   A                       
   10     DOC-FORMAT    BATCH-REC         +1     3   A                       
   11     TRADE-PARTNER BATCH-REC        +25     4   A                       
   12     PROCESS-DATE  BATCH-REC        +32     6   A                       
   13       PRCS-YY     PROCESS-DATE             2   A                       
   14       PRCS-MM     PROCESS-DATE     +2      2   A                       
   15       PRCS-DD     PROCESS-DATE     +4      2   A                       
   16     BATCH-NBR     BATCH-REC        +44     5   N                       

 71 JOB INPUT KS400    START 0500-INIT               
 72   IF RECID EQ '#210PROD', '#310PROD', '#810PROD'
 73     DISPLAY 'IF1'                               
 74     W-INVOICE-FLAG = 'Y'                         
 75     BATCH-REC = INPUT-REC                       



It's very strange, in below situations, the program runs fine.
1) Go into 3.4 and edit the file without making any changes and save&exit.
2) CC and PASTE the content to another dataset
3) REPRO the dataset SKIPREC(3).
The first 3 rows:

Code:

#301PROD  FROM MATNAV TO UNIS   080828 0007 04876                       
6057362 HD22065710                    APPRSHA 000000SHENDA IMPORT AND EX
6057362 OV22065710                                                     



It seems that the 3 rows will be ignored as per the program logic.
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2146
Location: At my coffee table

PostPosted: Wed Sep 03, 2008 4:36 pm
Reply with quote

And what happened to "0500-INIT"?
Back to top
View user's profile Send private message
michaeltai
Warnings : 1

New User


Joined: 23 Jul 2005
Posts: 20

PostPosted: Wed Sep 03, 2008 5:49 pm
Reply with quote

It's nothing but set flag, and accept current date.

Code:

0500-INIT.     PROC               
                                 
  W-INVOICE-FLAG = 'N'           
  WK-SYSDATE = SYSDATE           
  IF   WK-SYSDATE-M1   EQ   ' '   
       WK-SYSDATE-M1 = '0'       
  END-IF                         
  IF   WK-SYSDATE-YY   GE   '80' 
       WK-DATE-STAMP-CC = '21'   
  ELSE                           
       WK-DATE-STAMP-CC = '20'   
  END-IF                         
  WK-DATE-STAMP-YY = WK-SYSDATE-YY
  WK-DATE-STAMP-MM = WK-SYSDATE-MM
  WK-DATE-STAMP-DD = WK-SYSDATE-DD
  W-PRCS-CC =  WK-DATE-STAMP-CC   
  W-ISUE-CC =  WK-DATE-STAMP-CC   
                               
  WK-SYSTIME = SYSTIME           
  WK-TIME-STAMP-HH = WK-SYSTIME-HH
  IF WK-TIME-STAMP-H LT '0'       
     WK-TIME-STAMP-H =  '0'       
  END-IF                         
  WK-TIME-STAMP-MM = WK-SYSTIME-MM
  WK-TIME-STAMP-SS = WK-SYSTIME-SS
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Wed Sep 03, 2008 9:03 pm
Reply with quote

Hello,

Quote:
It seems that the 3 rows will be ignored as per the program logic.
Why do you believe they will be "skipped"?
Back to top
View user's profile Send private message
michaeltai
Warnings : 1

New User


Joined: 23 Jul 2005
Posts: 20

PostPosted: Thu Sep 04, 2008 7:03 am
Reply with quote

Because I add one display statament in each 'IF' loop to see those statement was displayed. They are not displayed, which means those records are ignored.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Sep 04, 2008 7:15 am
Reply with quote

Hello,

That does not mean they are being skipped - it only means they did not meet the condition of the IF.

If you post the next lines of code (after line 75) it may help.
Back to top
View user's profile Send private message
michaeltai
Warnings : 1

New User


Joined: 23 Jul 2005
Posts: 20

PostPosted: Fri Sep 05, 2008 2:00 pm
Reply with quote

Code:

JOB INPUT KS400    START 0500-INIT               
  IF RECID EQ '#210PROD', '#310PROD', '#810PROD'
    W-INVOICE-FLAG = 'Y'                         
    BATCH-REC = INPUT-HDR                       
    PERFORM 1000-INSERT-ICBH                     
  ELSE                                           
    IF W-INVOICE-FLAG = 'Y' AND HDRIF = 'HDR'   
      INVOICE-REC = INPUT-REC                   
      PERFORM 2000-INSERT-ICVE                   
  ELSE                                           
    IF RECID = '#EOT'                           
      W-INVOICE-FLAG = 'N'                       
    END-IF                                       
    END-IF                                       
  END-IF                                         


I think it's an data issue, since this program has run in production for many years. But I just can't identify which data led to the problem. I even using IDCAMS PRINT DUMP to compare.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sat Sep 06, 2008 3:43 am
Reply with quote

Hello,

Quote:
I think it's an data issue
Yes. Either that or a bug that has been lurking for many years. . . icon_wink.gif

You might look in the code for a reference to any field in batch-rec while processing any of these "ignored" records. Nothing has been moved there and any use of a field that should be numeric could cause the 0c7. This may be the first time the first records did not meet the IF condition.

You might try to initialize all of the fields in batch-rec with valid values before the JOB statement.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CA Products

 


Similar Topics
Topic Forum Replies
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Issues Converting From ZD to Signed N... DFSORT/ICETOOL 4
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
Search our Forums:

Back to Top