Explain about LMGET�read a logical record from a data set



Explain about LMGET�read a logical record from a data set..

Answer / dimpy19

1.The LMGET service reads one logical record from the data set associated with the given data ID.
2.Completion of the LMINIT and LMOPEN services for the data set is required before LMGET is invoked.
3.If the data to be processed is a sequential data set, the first LMGET reads the first logical record. Later invocations read successive logical records
4.If the data is an ISPF library or MVS� partitioned data set, previous completion of the LMMFIND service is required in addition to completion of LMINIT and LMOPEN.
The LMGET service reads from the last member referred to by the LMMFIND service in the data sets being processed. Thus, if LMMFIND is issued referencing member A,
LMGET reads from member A. If another LMMFIND is issued referencing member B, LMGET reads from member B, not member A.

>>-ISPEXEC--LMGET--DATAID(data-id)--MODE(-+-MOVE---+-)---------->
+-LOCATE-+
+-INVAR--+
'-MULTX--'

>--DATALOC(dataloc-var)--DATALEN(datalen-var)------------------->

>--MAXLEN(max-length)------------------------------------------><

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More JCL Interview Questions

Current version of GDG is ID.GDG.FILE.G0001V00. JCL has procedure with 2 steps like below,  What will be the output file name in each step ?  PROC starts      Step 1 has ID.GDG.FILE(+1)      Step2 has  ID.GDG.FILE(+4) PEND Similarly, JCL has 2 steps in 2 separate procedure. What will be the output file names here ?  PROC starts      Step 1 has ID.GDG.FILE(+1) PEND PROC1 starts      Step2 has  ID.GDG.FILE(+4) PEND

2 Answers   FIS,


Is condition checking possible in jcl?

0 Answers  


Could anyone please suggest me what is the maximum length of data that can be pass as input in //sysin dd * This was asked in interview. TIA

3 Answers   VC, Wipro,


i have two flat files.i want to select one record from that file by using jcl.for example file1 contains emp no,name,joining date. file2 has same details.emp no is primary key. i will give empno.that emp details send to outfile.please let me know if any one knows it.give sample code.

1 Answers   TCS,


suppose i have 10 job steps and i want to execute only step 6.How to write?

6 Answers  






I have a JCL which 20 steps. How do I execute 17 th step alone (It should execute only 17ths tep.and it should not execute 18,19,20 steps??

9 Answers   IBM, Infosys, TCS, Xansa, Xchanging,


What will happen if you attempt to restart a job in the middle of a JCL // IF .... // ENDIF?

4 Answers  


diff bw vsam and normal flat file?

2 Answers   CGI,


What is Backward Referencing ?

3 Answers   HSBC,


what are JCLLIB and STEPLIB in JCL?

0 Answers  


There are a set of 10 files and a customer will be selecting random no of files(i.e they may be more than 2, may not be in the order).Sometimes he might just select one file or sometimes no files at all.How do you code a JCL for this? Is it possible to code just JCL alone for this problem?

9 Answers   Infosys,


how do you code a null statement?

0 Answers   IBM,


Categories