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
 

 

I want a job to get input from user in run time.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> All Other Mainframe Topics
View previous topic :: :: View next topic  
Author Message
MChandrasekar

New User


Joined: 21 May 2007
Posts: 7
Location: Chennai

PostPosted: Wed May 30, 2007 11:10 am    Post subject: I want a job to get input from user in run time.
Reply with quote

Hi..,
Anyone of you Could you please send me one Run JCL to get the input data from the user during time instead passing the input values through SYSIN from the run JCL..

I am using IBM390 MVS z/os. icon_smile.gif
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: Wed May 30, 2007 11:23 am    Post subject:
Reply with quote

Nope, can not be done
Back to top
View user's profile Send private message
priyadutta1984

New User


Joined: 02 Apr 2007
Posts: 11
Location: chennai

PostPosted: Wed May 30, 2007 12:36 pm    Post subject: Re: I want a Run JCL to get input from user in run time.
Reply with quote

i dont think so its possible.make it ur query little bit clear.
u can pass the input thru parm and sysin card to the program.
cheers
priya
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Wed May 30, 2007 3:06 pm    Post subject:
Reply with quote

Chandrasekhar,

Quote:
Anyone of you Could you please send me one Run JCL to get the input data from the user during time instead passing the input values through SYSIN from the run JCL..


Does this mean, your program accepts the value from the terminal?
Back to top
View user's profile Send private message
MChandrasekar

New User


Joined: 21 May 2007
Posts: 7
Location: Chennai

PostPosted: Wed May 30, 2007 3:19 pm    Post subject: yes
Reply with quote

yes..,
My program has to ACCEPT the input value from the user in mainframe terminal.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1439
Location: Bangalore,India

PostPosted: Wed May 30, 2007 3:56 pm    Post subject:
Reply with quote

Chandrasekar,

Use ACCEPT var-name FROM CONSOLE in COBOL. Theortically it waits for user input from console. But I have not tried this before. Try and let us know the result.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10210
Location: italy

PostPosted: Wed May 30, 2007 4:01 pm    Post subject: Re: I want a Run JCL to get input from user in run time.
Reply with quote

It works, but there is a 99.99 % chance that the operator will cancel the job
regards

P.S.

console input is not considered a good interface/programming standard
Back to top
View user's profile Send private message
MChandrasekar

New User


Joined: 21 May 2007
Posts: 7
Location: Chennai

PostPosted: Wed May 30, 2007 5:33 pm    Post subject:
Reply with quote

Use ACCEPT var-name FROM CONSOLE in COBOL.

this is not working.
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: Wed May 30, 2007 5:45 pm    Post subject: Re: I want a Run JCL to get input from user in run time.
Reply with quote

That's a valid COBOL statement.

What specifically do you mean by "this is not working."?

I did a quick test with this program:

Code:

CBL ARITH(EXTEND)                                             
CBL NOADV,NODYN,NONAME,NONUMBER,QUOTE,SEQ,XREF,VBREF,DUMP,LIST
CBL TRUNC(OPT)                                                 
       IDENTIFICATION DIVISION.                               
       PROGRAM-ID. XXXXXXXX.                                     
       ENVIRONMENT DIVISION.                                   
       INPUT-OUTPUT SECTION.                                   
                                                               
       DATA DIVISION.                                         
       FILE SECTION.                                           
                                                               
       WORKING-STORAGE SECTION.                               
       01  CONSOLE-DATA          PIC X(80).                                                           
                                                 
       PROCEDURE DIVISION.                       
           ACCEPT CONSOLE-DATA FROM CONSOLE.     
           DISPLAY CONSOLE-DATA.                 
           MOVE 0 TO RETURN-CODE.               
           STOP RUN.       


runtime output:

Code:
             
08.12.31 JOB22654 ---- WEDNESDAY, 30 MAY 2007 ----                             
08.12.31 JOB22654  IRR010I  USERID SUPERK  IS ASSIGNED TO THIS JOB.           
08.12.32 JOB22654  ICH70001I SUPERK  LAST ACCESS AT 08:08:02 ON WEDNESDAY, MAY
08.12.32 JOB22654  $HASP373 SUPERK# STARTED - INIT 68   - CLASS T - SYS SYSB   
08.12.32 JOB22654  IEF403I SUPERK# - STARTED - TIME=08.12.32                   
08.12.32 JOB22654 @12 IGZ0000I AWAITING REPLY                                   
08.12.55 JOB22654  R 12,TEST                                                   
08.12.55 JOB22654  IEF404I SUPERK# - ENDED - TIME=08.12.55                     
08.12.55 JOB22654  $HASP395 SUPERK# ENDED                                     


SYSOUT Output:

Code:

TEST     
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: Wed May 30, 2007 6:21 pm    Post subject:
Reply with quote

Isn't this accepting input from the master console rather than the users terminal.

If so, doesn't this mean that the operations people will need to supply the response rather than the user ?

Unless of course it is carte blanche for all users to reply to system messages on the system ............................. icon_evil.gif
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: Wed May 30, 2007 6:26 pm    Post subject:
Reply with quote

expat wrote:
Isn't this accepting input from the master console rather than the users terminal.


Yes, of course.

expat wrote:
If so, doesn't this mean that the operations people will need to supply the response rather than the user?


Not necessarily.

expat wrote:
Unless of course it is carte blanche for all users to reply to system messages on the system


It's allowed in our shop.
Back to top
View user's profile Send private message
dick scherrer

Site Director


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

PostPosted: Wed May 30, 2007 7:21 pm    Post subject:
Reply with quote

Hello,

For this
Quote:
Anyone of you Could you please send me one Run JCL to get the input data from the user during time instead passing the input values through SYSIN from the run JCL..
i'd suggest providing the user(s) with a CICS transaction that would read the value from the terminal, edit it as appropriate, and then submit JCL that included the user-supplied input through the internal reader.

Somewhere between many and most data center operations do not allow console interaction with application code.
Quote:
Use ACCEPT var-name FROM CONSOLE in COBOL.

this is not working.
what does "not working" mean? Even if it works, how is the interface between the user who is running the job and the console operator to be handled? I do not recall any site that allows business users to reply to operator console messages - system support folks yes, but business users, no icon_confused.gif Seems like that would be extremely dangerous.
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: Wed May 30, 2007 7:31 pm    Post subject:
Reply with quote

Quote:
It's allowed in our shop.

What, absolutely anyone can respond to console messages icon_eek.gif icon_eek.gif icon_eek.gif

It only takes one inquisitive person to reply to the wrong message, and maybe the production system drops. Once had a programmer do a $P command to see what it does ...................... needless to say he found out, just before being hoofed out.
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: Wed May 30, 2007 7:35 pm    Post subject: Re: I want a job to get input from user in run time.
Reply with quote

Reply to a WTOR, yes. Issue an MVS or JES command, limited and to only certain commands based on roles.
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 -> All Other Mainframe Topics All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts DD DUMMY & CPU TIME Nileshkul Testing & Performance analysis 16 Mon Dec 19, 2016 11:35 pm
No new posts Performing arithmetic on input field zh_lad DFSORT/ICETOOL 31 Tue Dec 06, 2016 8:04 pm
No new posts High CPU consumption Job using IAM fi... aswinir JCL & VSAM 15 Thu Dec 01, 2016 8:28 pm
This topic is locked: you cannot edit posts or make replies. Get a job submitted itself every time... arunsoods JCL & VSAM 3 Tue Nov 22, 2016 4:05 pm
No new posts Check System time(Minute) Using TIME1... balaji81_k DFSORT/ICETOOL 5 Fri Nov 11, 2016 10:53 am


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