View previous topic :: View next topic
|
Author |
Message |
sai.dara
New User
Joined: 24 Aug 2007 Posts: 12 Location: Hyderabad
|
|
|
|
How do yo u accept input data from JCL in PLI ? what extra code we need to put like in cobol we give Linkage Section and Procedure Division with variables etc. |
|
Back to top |
|
|
prino
Senior Member
Joined: 07 Feb 2009 Posts: 1306 Location: Vilnius, Lithuania
|
|
|
|
Code: |
myproc: proc(parm) options(main);
dcl parm char (100) var;
.
.
.
end myproc; |
Code: |
//STEPPLI EXEC PGM=MYPGM,PARM='/PARAMETERS' |
Before the slash you can put parameters for the run-time.
FWIW, everything is in the manual, why did you not read it??? |
|
Back to top |
|
|
sai.dara
New User
Joined: 24 Aug 2007 Posts: 12 Location: Hyderabad
|
|
|
|
Thank You Prino.
I have a query, in the above PLI program you have declare the variable name as "parm"
dcl parm char (100) var;
as we are passing data from PARM parameter of JCL, is it mandatory to declare the name as PARM of can I give a different name.
One more thing if we are passing data from SYSIN, what name should we give to the variable that accepts the input.
//SYSIN DD *
this is input
/* |
|
Back to top |
|
|
prino
Senior Member
Joined: 07 Feb 2009 Posts: 1306 Location: Vilnius, Lithuania
|
|
|
|
"Oh crap", as Joy Turner would say...
Code: |
dcl volume area;
dcl integer float;
dcl float char;
if if = then then then = else;else else = if;
|
How much trouble would it have been to try this:
Code: |
myproc: proc(I_am_a_dimwit) options(main);
dcl I_am_a_dimwit char (100) var;
.
.
.
end myproc; |
As for SYSIN? You can treat it as a normal file, or you can treat it as SYSIN. Either way, RTFM! |
|
Back to top |
|
|
|