MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Control not going to next perform
Goto page 1, 2  Next
 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming
View previous topic :: View next topic  
Author Message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Tue Jan 30, 2007 2:18 pm    Post subject: Control not going to next perform Reply with quote

I need a help guys. I am trying to test the below code and I see that after the perform A1000-process, the control is not going to PERFORM 3600-WRITE-DETL-CUST-IIR . I tried a display statement and even its not displayed in sysout. I used xped and surprised to see that the control is not at all going to the display statement. I know there is something I am missing.
Any help is greatly appreciated.


Code:

IF T009-CD = 12
  PERFORM A1000-PROCESS                               
        UNTIL HOLD-CC-GRP NOT = T20-BT-CC-GRP
        OR EXTRACT-EOF                             
                 
  PERFORM 3600-WRITE-DETL-CUST-IIR     
Display ' I am here'           
 ELSE         
     CONTINUE 
 END-IF       
                                         
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Tue Jan 30, 2007 2:28 pm    Post subject: Reply with quote

vak255,

what are the values of HOLD-CC-GRP & T20-BT-CC-GRP ? Pay attention to the NOT relational operator. If HOLD-CC-GRP is NOT equal to T20-BT-CC-GRP , then only you will perform 3600- write paragrap.
ex:
Code:

IF T009-CD = 12
   PERFORM A1000-PROCESS
     UNTIL HOLD-CC-GRP NOT = T20-BT-CC-GRP
        OR EXTRACT-EOF
           PERFORM 3600-WRITE-DETL-CUST-IIR
           Display ' I am here'           
ELSE         
  CONTINUE 
END-IF       



Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu


Last edited by kolusu on Tue Jan 30, 2007 2:44 pm; edited 1 time in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
programmer1
Beginner


Joined: 18 Feb 2004
Posts: 138
Topics: 14

PostPosted: Tue Jan 30, 2007 2:29 pm    Post subject: Reply with quote

There can be many reasons for this:

1) HOLD-CC-GRP is always equal to T20-BT-CC-GRP and
2) EXTRACT-EOF is never true
3) May be the control is not coming back from A1000-PROCESS para. Try using an end para statement

Are you getting an abend while executing the code ?

A lot could depend on what is happening within A1000-PROCESS
_________________
Regards,
Programmer
Back to top
View user's profile Send private message
programmer1
Beginner


Joined: 18 Feb 2004
Posts: 138
Topics: 14

PostPosted: Tue Jan 30, 2007 2:32 pm    Post subject: Reply with quote

Ohh,

The boss was here !
_________________
Regards,
Programmer
Back to top
View user's profile Send private message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Tue Jan 30, 2007 2:34 pm    Post subject: Reply with quote

Kolusu sorry for the confusion, A1000-PROCESS is a separate paragraph and 3600-WRITE-DETL-CUST-IIR is a different para. So I expect after the Perform A1000-PROCESS is executed , PERFORM 3600-WRITE-DETL-CUST-IIR should be executed and then the display.
Thanks for your time.

Quote:

IF T009-CD = 12
PERFORM A1000-PROCESS UNTIL HOLD-CC-GRP NOT = T20-BT-CC-GRP PERFORM 3600-WRITE-DETL-CUST-IIR
Display ' I am here'
ELSE
CONTINUE
END-IF
Back to top
View user's profile Send private message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Tue Jan 30, 2007 2:35 pm    Post subject: Reply with quote

I facing some problems with the formatting,
IF T009-CD = 12
PERFORM A1000-PROCESS UNTIL HOLD-CC-GRP NOT = T20-BT-CC-GR
PERFORM 3600-WRITE-DETL-CUST-IIR
Display ' I am here'
ELSE
CONTINUE
END-IF
Back to top
View user's profile Send private message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Tue Jan 30, 2007 2:37 pm    Post subject: Reply with quote

Programmer,

i am not facing any abends. thanks.
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Tue Jan 30, 2007 2:43 pm    Post subject: Reply with quote

vak255,


Run this code and see how the perform works.

Code:

WORKING-STORAGE SECTION.                         
01 WS-A                  PIC X(01) VALUE 'A'.   
01 WS-B                  PIC X(01) VALUE 'C'.   
01 WS-C                  PIC X(01) VALUE 'C'.   
01 WS-CNT                PIC S9(04) COMP VALUE 0.
PROCEDURE DIVISION.                             
   IF WS-A = 'A'                                 
      PERFORM A100-DISP                         
         UNTIL WS-B NOT = WS-C                   
            OR WS-CNT  > 10                     
               PERFORM B100-DISP-B               
               DISPLAY ' I AM HERE '             
    ELSE                                         
      CONTINUE                                   
    END-IF                                       
    GOBACK                                       
    .                                           
                                                 
A100-DISP.                                       
    ADD  +1  TO WS-CNT                           
    DISPLAY 'A100-DISP  ' WS-CNT                 
    IF WS-CNT = 5                               
       MOVE 'B' TO WS-B                         
    END-IF                                       
    .                                           
B100-DISP-B.                                     
    DISPLAY 'B100-DISP  ' WS-CNT                 
    .                                           


the out put would be as follows

Code:

A100-DISP  0001
A100-DISP  0002
A100-DISP  0003
A100-DISP  0004
A100-DISP  0005
B100-DISP  0005
 I AM HERE     

_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
programmer1
Beginner


Joined: 18 Feb 2004
Posts: 138
Topics: 14

PostPosted: Tue Jan 30, 2007 2:43 pm    Post subject: Reply with quote

when you ran this code using xpediter, where did the control go after A1000-PROCESS ?

Did you check up on the conditions that I mentioned in the earlier post?
_________________
Regards,
Programmer
Back to top
View user's profile Send private message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Tue Jan 30, 2007 2:51 pm    Post subject: Reply with quote

Kolusu and programmer,
Thanks kolusu, thats what I am exactly expecting.
I will check the conditions and will update you.
Back to top
View user's profile Send private message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Tue Jan 30, 2007 3:11 pm    Post subject: Reply with quote

I think I am close to the error.
I like to know one more thing, I am getting some warnings when I compiled the pgm,
Can anyone please explain me a little bit on this.
Quote:

IGYOP3094-W THERE MAY BE A LOOP FROM THE "PERFORM" STATEMENT AT "PERFORM
Back to top
View user's profile Send private message
blitz2
Beginner


Joined: 23 Jan 2007
Posts: 84
Topics: 14

PostPosted: Wed Jan 31, 2007 8:16 am    Post subject: Reply with quote

1) how about posting your A1000- para?
2) search for IGYOP3094-W in the program listing. Can you post 10 lines (both before and after) from the code where you find it?
________
weed vaporizer


Last edited by blitz2 on Wed Feb 02, 2011 3:10 am; edited 1 time in total
Back to top
View user's profile Send private message
vak255
Intermediate


Joined: 10 Sep 2004
Posts: 384
Topics: 79

PostPosted: Wed Jan 31, 2007 4:15 pm    Post subject: Reply with quote

Here is it, can I ignore the warning.

Code:

 PERFORM 3100-READ-EXTRACT-IIR                   
                                                     
    IF EXTRACT-EOF                                   
       PERFORM 3201-READ-SORTED-IIR UNTIL           
               HOLD-SORT-IIR(1:6) = 'M$9002'         
         SET SORT-IIR-EOF TO TRUE                   
                                                     
       PERFORM 3401-READ-FORMAT-IIR UNTIL           
               T258-DOC-FRMT-TRGR-REC(1:6) = '9002'
         SET FORMAT-EOF TO TRUE                     
    ELSE                                             
      IF SORT-IIR-NOT-EOF                           
       AND HOLD-BTN-CC-GRP NOT = T259-BTN-CC-GRP     
       PERFORM 3200-READ-SORTED-IIR                   <---- this where I am getting the warning.           
                                                     
     END-IF                                               
                                                         
     PERFORM 3300-EVAL-FIT-CTGY-CD                       
     PERFORM 3400-READ-FORMAT-IIR                         
                                                         
     IF FORMAT-NOT-EOF                                   
       PERFORM 3500-POPULATE-DETL-CUST                   
       PERFORM 3600-WRITE-DETL-CUST-IIR                   
       PERFORM UNTIL HOLD-BTN-CC-GRP NOT = T259-BTN-CC-GRP
               OR EXTRACT-EOF                             
         IF B2CCT293-88                                   
           PERFORM 3700-POPULATE-DET-TAX                 
           PERFORM 3800-WRITE-DETL-TAX-IIR               
         ELSE                                             
           IF B2CCT355-88                                 
             CONTINUE                                     
           ELSE                                           
             PERFORM 3900-POPULATE-DETL-BILL             
             PERFORM 3990-WRITE-DETL-BILL-IIR             
           END-IF
Back to top
View user's profile Send private message
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Thu Feb 01, 2007 12:31 am    Post subject: Reply with quote

I guess you also need to show A100-, 3200- and 3600- paras.
Back to top
View user's profile Send private message Send e-mail
hareshh
Beginner


Joined: 13 Dec 2006
Posts: 16
Topics: 0

PostPosted: Thu Feb 01, 2007 1:02 am    Post subject: Reply with quote

Hi Kiran,

I think you need Explicit scope terminator i.e. END-IF.

ELSE
IF SORT-IIR-NOT-EOF
AND HOLD-BTN-CC-GRP NOT = T259-BTN-CC-GRP
PERFORM 3200-READ-SORTED-IIR <---- this where I am getting the
END-IF Arrow
END-IF

Try it Exclamation

Regards,
Haresh.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> Application Programming All times are GMT - 5 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group