PL/I programming language used on IBM Mainframes
Questions tagged [pl-i]
29 questions
1
vote
1 answer
How to print a UTF-8 unicode string as EBCDIC in PL/I
How can I instruct PL/I to print a UTF-8 value as EBCDIC. Is there a "trick" in PL/I or do I have to call the z/OS unicode services to convert the UTF-8 value?
PUT SKIP EDIT('VAR: ',VAR) (A,A);
Using the above instruction gives unreadable…

Tomek Dobrzynski
- 87
- 1
- 7
1
vote
1 answer
passing data from sysin jcl to PL/I program
I need to pass data from SYSIN JCL to PL/I program. Below is my code from JCL and PL/I program and values are not being passed. Can anyone help please?
//SYSIN DD *
12345
PROG: PROC(INPARM) OPTIONS(MAIN REENTRANT) REORDER;
DCL INPARM …

Gagandeep Singh Randhawa
- 157
- 1
- 3
- 14
1
vote
0 answers
How to pass input to get statement in PL/I
I am very new to PL/I.
I am using this compiler: http://iron-spring.com/.
I don't know how to pass the command-line arguments that the get statement is expecting to receive. It doesn't work for me to just type them in the command line (as I'm used…

maxfried
- 21
- 4
1
vote
1 answer
Measuring db2 pl1 program execution time on TEST mode(Rollback)
There are two modes to execute a pl1 DB2 main program-
one with TEST mode. In this case, for each input record db2 statements in the sub program are executed as usual, but before completing the execution of single input processing Roll back is…

cobp
- 772
- 1
- 5
- 19
1
vote
1 answer
PL/I character set and IBM Personal Communications - wrong characters are displayed
Some characters that I enter in editor displayed not identical to those on keyboard. So I have error messages like this:
Character with decimal value 176 does not belong to the PL/I character
set. It will be ignored.
when trying to compile PL/I…

zer_ik
- 410
- 1
- 4
- 14
1
vote
3 answers
Error handling in PL/I when using an external DLL?
I am calling an external DLL from my PL/I module. The DLL takes a pointer to an array as an input and returns another pointer to an output array, alongwith an error message and a return code.
I have done suitable error handling (in my PL/I module)…

Soumik Das
- 276
- 2
- 14
0
votes
1 answer
Data Conversion from PIC to decimal (fixed)
I'm currently trying to divide a PIC number by 100 and then put the whole result (including the numbers after the floating point) into a fixed decimal (16,2).
My problem is, I'm not getting it to work and I only get 0 (instead 0.25 as example) if…

Thomas
- 2,886
- 3
- 34
- 78
0
votes
1 answer
How to use pointers in PL1 programming language
I am trying to learn the use of pointers in PL1. However below approach is not working
DCL MYPTR PTR;
DCL MYVAR CHAR(10) INIT('1234567890');
PUT SKIP(2) LIST('DISPLAY MYVAR: ',MYVAR);
MYPTR =…

Gagandeep Singh Randhawa
- 157
- 1
- 3
- 14
0
votes
2 answers
Jagged array PL1 (PL/I)
I need jagged dynamic array in PL/I but I don't know how to realize it.
Need something like:
dcl v dim(*,*) fixed bin(31) ctl;
allocate v dim(5,*);
allocate v(1) dim(10);
allocate v(2) dim(100);
How can I do it?

zer_ik
- 410
- 1
- 4
- 14
0
votes
2 answers
PL/I - How do I read a file in a loop without opening/closing the file multiple times
I have a program that is reading through a file(FILE1). For every record in FILE1 it gets the field 'A' and it searches through FILE2 to find a record with a matching value of field 'B'. When A = B some fields from both files are read out. The…

randomG765
- 63
- 1
- 13
0
votes
1 answer
pl/i enterprise dynamically allocate file
I'm trying to dynamically allocate file via
OPEN FILE (OUT) TITLE('DSN(XXXXX.XXXXX.MILTEST),LRECL(80)');
File is created but the record size is default value. I tried env variable and alternate name with DD_DDNAME but keep getting
UNDEFINEDFILE…

Milan Mlynarcik
- 1
- 1
0
votes
1 answer
Set address pointer to pointer in PL/I
I don't understand source code PL/I:
DCL AA CHAR(10) BASED(P1);
DCL BB CHAR(10) INIT ("BBBBBBBBBB");
DCL CC CHAR(10) INIT ("CCCCCCCCCC");
DCL DD CHAR(10) INIT ("DDDDDDDDDDD");
DCL ADDR BUILTIN;
DCL P1 PTR;
…

Cuong Huy
- 61
- 1
- 9
0
votes
1 answer
PL1 structure assignment with BY NAME option at runtime or compilation
In PL1 it is possible to assign a structure with the option BY NAME. Is this functionality used during runtime or during compile only?
The IBM documentation is not very helpful in this case.

B4dT0bi
- 623
- 4
- 21
-2
votes
1 answer
PL/I copybook to COBOL copybook
How to convert PL/I copybook to COBOL copybook.
2 PL_COPYBOOK.
3 FIRST_FIELD CHAR(20).
3 SECOND_FIELD FIXED(5).
3 THIRD_FIELD FIXED(9,0).
3 FOURTH_FIELD FIXED(7,1).
3 FIFTH_FIELD BIT(8).
3 SIXTH_FIELD FIXED BIN(15).

Mohit
- 5
- 1