Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Is SLEEP a better option ??
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Fri Jan 16, 2009 8:15 pm    Post subject: Is SLEEP a better option ??
Reply with quote

Hi,

I have a scenario where i need to run a cobol -program and based on the result , i need to decide my further course of action in a CLIST program which uses panels ( interactive mode ).
Basically the program will check whether a particular literal is found in a file or not.
I tried using the file directly in my clist using EXECIO command but the file is very huge and im unable to get the storage space needed for this operation.And i have tried the maximum available storage for my userid in TSO region.
Is SLEEP a better option to handle this case ?? or
Is there any other option ?? We cant invoke a interactive pgm from a batch job.
Back to top
View user's profile Send private message

superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Fri Jan 16, 2009 8:35 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

Is SLEEP a better option than what? What does running a COBOL program or reading/processing datasets have to do with storage limitations within TSO?
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Fri Jan 16, 2009 8:40 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

I thought of reading the file in my clist program itself to match the literal, but since the file is huge its running in the range of 5000 Mb .. and i'm unable to do an EXECIO operation to read the file because of the storage limitation.
Also i'm not sure if there is any other option other than using SLEEP ??
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Fri Jan 16, 2009 9:08 pm    Post subject:
Reply with quote

you are asleep at the wheel.

suggest you define your requirements - completely.

and stop trying to apply your preconcieved notions of a solution.

The only time I have seen a valid invokation of a 'sleep' was for a batch started task that ran 24/7. Sleep was used to help deal with -913's, etc...

why not CALL a cobol program from your REXX Script that would read the file and return a 'hit' or nofind situation.

I do not see a need for a delay in the scenario that you have not described.
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Fri Jan 16, 2009 9:25 pm    Post subject:
Reply with quote

If you want to find a string, then why can't you use SUPERC from within your CLIST?

O.
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Fri Jan 16, 2009 9:34 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

... or call a simple SORT routine?
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Fri Jan 16, 2009 9:36 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

Dick,
Im automating a process which requires a set of jcls to be run. I need some parameters to be passed to the jcls.I'm getting this set of parameters from the user via a Panel (interactive mode). And now i need to validate the parameters entered by the user.For validating one of the parameter i need to check it against a file which is very huge.Now if the parm entered by the user is not found in the file i need to throw an error
message in the panel asking the user to enter a valid parm.

So to do this i need to read the file and do the validation. I'm unable to read the file in the REXX because of the storage limitaions ( My program abends with a message EXECIO : Unalble to obtain storage ).

I hope i'm clear here.
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Fri Jan 16, 2009 9:39 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

And when i use a cobol program or sort routine suggested by Kevin i cant invoke the rexx again from batch mode to display panel.

Pls let me know if i'm still not clear.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Fri Jan 16, 2009 9:56 pm    Post subject:
Reply with quote

Fridays?
why not invoke the 'superc'/'sort'/'cobol' method of validating the parm from the REXX?????????????????????????????????????????
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Sat Jan 17, 2009 2:39 am    Post subject:
Reply with quote

ramp_senti

Having seen the suggestions and advice offered by very experienced people, dare I ask, are you sure that your chosen profession is the correct one ?
Back to top
View user's profile Send private message
superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4648
Location: Raleigh, NC, USA

PostPosted: Sat Jan 17, 2009 2:52 am    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

The other piece of this puzzle that hasn't been made clear is why, if a REXX exec is not capable of doing what needs to be done, but a COBOL program is, is this process not coded in COBOL?

(not that I ever doubt the capabilities of a well-written exec).
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Sat Jan 17, 2009 4:50 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

I dont know wats the problem here !! Is it i'm not explaining well / or you folks not understanding the scenario / or me not understanding the one line solutions provided so far !!

Ill be happy if any of you can validate my understanding.

My understanding is this
* the storage available for the Execs is the storage available for your TSO session.
* One can't invoke a EXEC in a interactive mode displaying panels and receiving inputs from user from a batch program.
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Sat Jan 17, 2009 4:51 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

job !! not program
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Sat Jan 17, 2009 5:34 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

To EXPAT :
I guess Yes !! coz i haven't heard such a question so far from relevant folks !!
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Sat Jan 17, 2009 5:41 pm    Post subject:
Reply with quote

I think that the problem is that many people have suggested that you are going in the wrong direction to resolve your issue, yet you are determined to follow that direction come what may.

Scenario - Your CLIST/REXX has submitted a job and there are processing problems or delays, and your submitted job sits waiting for an initiator for example 90 minutes. During this 90 minute period your terminal is locked and unusable for any other purpose.

You say a huge file, how many records and what is the LRECL. There are posts on the forum that deal with huge files using REXX. (I assume that your program is REXX as you say that your are using EXECIO). Did you use EXECIO to read the whole file, did you try to read only one record at a time, did you try processing blocks of records.

Have you considered using VSAM for your reference file, because you can invoke IDCAMS to select single or multiple key values and validate that way, rather than process a huge file. One or two reads and you are there.

Have you tried the suggestion of DBZ and invoking the sort or program from REXX/CLIST to see if that works ?

What is wrong with batch notification ? The job ends either sucessfully or not and issues a message to the user terminal with the return code. What about email notification from the job, either sucessful or not.

There are a good many years of experience on this forum from the senior members who have been there, seen that and have the T shirt to prove it. We are not having a pop at you personally, merely suggesting viable alternatives for your problem. Obviously at the end of the day if you choose to ignore or follow our suggestions is entirely up to you.
Back to top
View user's profile Send private message
ramp_senti

New User


Joined: 17 Mar 2006
Posts: 26

PostPosted: Sat Jan 17, 2009 6:50 pm    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

Eye opened Sir !!

I haven't tried the EXECIO to read a block of records !! Will try that !!Actually this is wat i was looking for !!

Actually somebody suggested this SLEEP but only after scanning the forum i learnt that SLEEP is not advisable !! just was looking for other options !!

Thanks a lot !!
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 401
Location: Mumbai

PostPosted: Sun Jan 18, 2009 4:02 am    Post subject: Reply to: Is SLEEP a better option ??
Reply with quote

Scenario sounds like it should be this. All done in Rexx exec.

  1. Rexx starts and goes into display loop
  2. Rexx issues ISPF display to get information and returns from display
  3. Rexx does allocations for verification program and starts verification program using TSO's CALL or ISPF's SELECT service
  4. Rexx examines return code from verification program and redisplays panel with a message if necessary or leaves display loop and continues
Note that there is no batch job involved here at all. Waiting on a batch job from an online program is a bad design. You can optimize this many ways, some of which have been suggested. Use a real data base instead of a sequential fiile, read the file once and keep keys in memory such as Rexx stem variable (use the keys as stem tails and check for the existence of the tail; don't save a separate tail for each record). Do the program calls from a Rexx panel exit (advanced and may not work but keeps the main rexx program from dealing with the problem). There are many designs possible but the more work you do up front , the less time the user will sit waiting at the terminal.

You can use EXECIO to read n records at a time instead of reading the whole file. That will fix the problem of running out of storage.
Back to top
View user's profile Send private message
Douglas Wilder

Active User


Joined: 28 Nov 2006
Posts: 305
Location: Deerfield IL

PostPosted: Tue Jan 20, 2009 9:31 pm    Post subject:
Reply with quote

Quote:
* One can't invoke a EXEC in a interactive mode displaying panels and receiving inputs from user from a batch job.
But one can invoke a program from a REXX without submitting a batch job.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Tue Jan 20, 2009 9:34 pm    Post subject:
Reply with quote

to associate the word ONLINE with tso interactive panels is a stretch.
no, it is actually a mis-statement.

and as Mr. Wilder has mentioned, the need to execute a batch job and wait is not necessary.

You can invoke the cobol module directly from REXX.
Back to top
View user's profile Send private message
MBabu

Active User


Joined: 03 Aug 2008
Posts: 401
Location: Mumbai

PostPosted: Wed Jan 21, 2009 5:11 am    Post subject:
Reply with quote

While technically correct, it is a misstatement - the correct term is "foreground", though only because "online" is traditionally reserved for CICS and similar OLTPs. Though notice that even the acronym OLTP makes a distinction between the OL and TP part.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts BWO option in VSAM blayek CICS 3 Sat Nov 05, 2016 10:47 am
No new posts Regarding COBOL Stored Procedure opti... selvamsrinivasan85 DB2 4 Fri Nov 04, 2016 8:57 pm
No new posts Compiler option for override the exte... muralikrishnan_new COBOL Programming 9 Fri Jul 08, 2016 12:09 pm
No new posts ICETOOL higher option Anshul Das DFSORT/ICETOOL 14 Thu Apr 14, 2016 8:00 am
No new posts CEXEC not able to execute if no SLINE... boyti ko CLIST & REXX 2 Wed Apr 13, 2016 4:31 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us