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

BDISPMAX exceeded ERROR


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Thu Jul 23, 2009 5:29 pm
Reply with quote

Hi,

I am trying to execute a REXX program in batch mode.
When i submitted the JCL i got MAXCC=990, which means 'BDISPMAX exceeded ERROR'.
I increased the range of BDISPMAX but now its giving S322 error.


ISPSTART CMD(%TEMPNAME) NEWAPPL(ISR)BDISPMAX(99999)


Can somebody help to resolve the same?

Thanks,
Marina.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jul 23, 2009 5:49 pm
Reply with quote

Yeah, it's in line 301 of your REXX code.

Unless we have the slightest idea of what you are trying to do, the way you are trying to do it, the above answer is about as good as it gets.

What does your program do,
Have you used TRACE to see what happens where
Back to top
View user's profile Send private message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Thu Jul 23, 2009 5:51 pm
Reply with quote

I did not understand what u meant by 'Its in line 301 of your REXX code'.

Please elaborate.


Thanks,
Marina.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Jul 23, 2009 5:59 pm
Reply with quote

MARINA JOSEPH wrote:
I did not understand what u meant by 'Its in line 301 of your REXX code'.

Please elaborate.


Thanks,
Marina.


read expat's next three lines. Attempt to take the post in context.

essentially, you told us: I have a problem with REXX.
and now you want a solution.
based on the info you provided us,
telling you that line 301 in your rexx script is the problem,
is as close as we can get.......................................
Back to top
View user's profile Send private message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Thu Jul 23, 2009 6:04 pm
Reply with quote

Below is my REXX program. It works perfectly fine when not run as a batch program.
There is no looping.
Any idea what could be the problem when i am trying to run the same in batch?

Code:

/*REXX*/                                                       
FILEIN = G68462.RULES.FILE                                   
PDSNAME = G68462.JOB.TOOL
DSNAME = G68462.JOB.JCL
                                                               
/*CHECK IF THE LIBRARY EXISTS OR NOT*/                         
/*INVOKING ISPF FILE SERVICES*/                               
                                                               
IF SYSDSN("'"PDSNAME"'") = 'OK' THEN                           
DO                                                             
   "ISPEXEC LIBDEF ISPSLIB DATASET ID('"PDSNAME"')"           
                                                               
    IF SYSDSN("'"DSNAME"'") = 'OK' THEN                       
    DO                                                         
       "ISPEXEC LIBDEF ISPFILE DATASET ID('"DSNAME"')"         
       IF SYSDSN("'"FILEIN"'") = 'OK' THEN                     
       DO                                                     
          "ALLOC DSN('G68462.RULES.FILE')DDN(INDSET)SHR REUSE"
          "EXECIO * DISKR INDSET(STEM REC.)"     
           IF REC.0 > 0 THEN                                           
           DO                                                           
              "ISPEXEC FTOPEN"                                         
               DO I = 1 TO REC.0                                       
                 PARSE VAR REC.I JOBNAME TIME                           
                 JNAME= STRIP(JOBNAME)                                 
                 JSTEP = I                                             
                 SAY I                                                 
                 "ISPEXEC FTINCL JOBSKL"                               
              END                                                       
           END                                                         
       END                                                             
    END                                                                 
END                                                                     
                                                                       
"ISPEXEC FTCLOSE NAME(REXXJCL) LIBRARY(ISPFILE)"                       
                                                                       
/*********************************************************************/
/* INVOKING MACRO TO INSERT THE JOB CARD                             */
/*********************************************************************/
                                                                       
"ISPEXEC EDIT DATASET('"DSNAME"') MACRO(INSERTJC) CONFIRM(YES)"         
EXIT
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jul 23, 2009 6:19 pm
Reply with quote

Can you post the macro code as well
Back to top
View user's profile Send private message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Thu Jul 23, 2009 6:41 pm
Reply with quote

Below is the MACRO code:-
It is for adding the job card.

Code:

ADDRESS ISREDIT "MACRO"                                               
IF RC  \=0 THEN EXIT                                                   
                                                                       
/* ADD THE JOB CARD   */                                               
DROP REC.                                                             
R = "//THD95Q1A JOB (02144T,02007211),TEST,CLASS=A,PRTY=4,MSGCLASS=X,";
REC.1 = R                                                             
REC.2 = "//         NOTIFY="||USERID()                                 
REC.0 = 2                                                             
                                                                       
DO I = 1 TO REC.0 ;                                                   
   SAY REC.I                                                           
   ADDRESS ISREDIT 'LINE_AFTER' I-1 '= "'REC.I'"' ;                   
END;       


Thanks,
Marina.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jul 23, 2009 6:56 pm
Reply with quote

Have you tried running it again - use a lower number for BDISPMAX(99999) to save time, maybe 999 and using TRACE R

And look through the trace and see what is happening where.

From a first glance I can see nothing glaringly obvious, so again suggest that you trace this.
Back to top
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2546
Location: Silicon Valley

PostPosted: Thu Jul 23, 2009 7:08 pm
Reply with quote

Quote:
It works perfectly fine when not run as a batch program.

Not sure what you mean by
fine', but you should start from TSO READY and then be back to TSO READY afterwards when you test it.

If it is in batch, you need to code your program and macro so that no panels are displayed. Afterall, you cannot display a panel in batch.

Make sure your edit macro ends the editor without displaying.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jul 23, 2009 7:41 pm
Reply with quote

I have had a play with TRACE on your code and found that the error is somewhere inside the macro. Couldn't be asked to look further because ....

Why on earth you need a macro to insert a jobcard when you are already using file tailoring is a mystery to me. I changed your code to put the jobcard in first and then add the other bits after. Works like a dream.

Code:

"EXECIO * DISKR INDSET ( STEM  STEMNAM. "
IF STEMNAM.0 > 0 THEN DO         
  "ISPEXEC FTOPEN"               
  "ISPEXEC FTINCL JOBCARD"       
  DO AA = 1 TO STEMNAM.0         
    PARSE VAR REC.I JOBNAME TIME 
    JNAME= STRIP(JOBNAME)         
    "ISPEXEC FTINCL JOBSKL"       
  END                             
  "ISPEXEC FTCLOSE NAME(REXXJCL)"
END                               
Back to top
View user's profile Send private message
Pedro

Global Moderator


Joined: 01 Sep 2006
Posts: 2546
Location: Silicon Valley

PostPosted: Thu Jul 23, 2009 9:02 pm
Reply with quote

Quote:
...i got MAXCC=990, which means 'BDISPMAX exceeded ERROR'.

How did you determine that the 990 return code meant a BDISPMAX error?
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 400
Location: Mumbai

PostPosted: Fri Jul 24, 2009 2:31 am
Reply with quote

Your macro needs to exit the editor . Use the ISREDIT END command. Otherwise you continue to sit in the editor, ISPF presses the virtual enter key 100000 times and ... BDISPMAX exceeded.
Back to top
View user's profile Send private message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Fri Jul 24, 2009 10:21 am
Reply with quote

The requirement that i have is to create a JCL which has a few job steps corresponding to the job names passed to it.
The job card needs to appear only once.
You cant insert the job card first as the Skeleton JCL will start fresh everytime and the job card gets overwritten.
Which is why i included it at the end.

Correct me if i am wrong.

Thanks,
Marina.
Back to top
View user's profile Send private message
MARINA JOSEPH

New User


Joined: 11 Jun 2009
Posts: 61
Location: chennai

PostPosted: Fri Jul 24, 2009 10:45 am
Reply with quote

Hey expat,

Your solution worked, i removed the MACRO and followed your method.
It works perfectly fine.

Thanks a lot.

Thanks,
Marina.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Fri Jul 24, 2009 2:40 pm
Reply with quote

Quote:
Hey expat,
Your solution worked, i removed the MACRO and followed your method.
It works perfectly fine.

And you had doubts icon_cry.gif

If you do need a macro to insert things into a dataset when not using file tailoring, I find it is far easier to keep the inserts in a seperate library and insert the whole member in one hit. It keeps it a whole lot cleaner than generating the JCL in the REXX code, and means that not only can the same member be used anywhere else that I want, but if it needs to be changed it only needs to be changed once.

This is the macro that I use to insert a jobcard at the top of a JCL stream.
Code:

"ISREDIT MACRO"
"ISREDIT COPY 'My ISPSLIB library(JOBCARD)' AFTER "0
"ISREDIT END"
Back to top
View user's profile Send private message
nkumar

New User


Joined: 09 Mar 2008
Posts: 28
Location: USA

PostPosted: Tue Oct 18, 2011 10:51 pm
Reply with quote

I know this is more than 2 year old post but wanted to Thank MBabu.

I was facing similar problem (ISPP330 BDISPMAX exceeded) while executing an ISPF Edit Macro program.

Problem was solved when I added ISREDIT END at end of my MACRO.

THANK YOU MBABU.
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 -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts Error to read log with rexx CLIST & REXX 11
No new posts Error when install DB2 DB2 2
No new posts CLIST - Virtual storage allocation error CLIST & REXX 5
No new posts Error while running web tool kit REXX... CLIST & REXX 5
No new posts ISPP330 BDISPMAX exceeded CLIST & REXX 12
Search our Forums:

Back to Top