How can we find out whether the job is interactive or Batch
through RPG program?
2) How can we find out through CL program?

Answers were Sorted based on User's Feedback



How can we find out whether the job is interactive or Batch through RPG program? 2) How can we fi..

Answer / rakesh

using RTVJOBA command...
if the TYPE option gives value "1" then it is interactive job.
if the value is "0" it is batch job

Is This Answer Correct ?    50 Yes 0 No

How can we find out whether the job is interactive or Batch through RPG program? 2) How can we fi..

Answer / syam

use WRKACTJOB. There is "Type" field. If under Type any job
is showing "INT" = Interactive, 'BCH" = Batch, "SBS" =
Subsystem, "SYS" = System, "WTR" = Writer(Printer).
Batch job will run in QBATCH Subsystem/Job and Interactive
job will run in QINTER Subsystem/Job.

Is This Answer Correct ?    17 Yes 6 No

How can we find out whether the job is interactive or Batch through RPG program? 2) How can we fi..

Answer / sweta p rao

QUSRJOBI API can be used to find out whether the job is
interactive or batch from RPG program

Field QUSJT04 will contain B for batch or I for interactive

Is This Answer Correct ?    11 Yes 2 No

How can we find out whether the job is interactive or Batch through RPG program? 2) How can we fi..

Answer / rashmimalpani

I think...Also for an RPG program if it has display-device
as WORKSTN then it should be interactive program... Please
correct me if m wrong

Is This Answer Correct ?    11 Yes 7 No

How can we find out whether the job is interactive or Batch through RPG program? 2) How can we fi..

Answer / sreedhar reddy

in RPG, Use PSDS data structure to find Job name.

position 244 to 253 is Job name.

D JOB_NAME 244 253 Job name

Is This Answer Correct ?    1 Yes 0 No

How can we find out whether the job is interactive or Batch through RPG program? 2) How can we fi..

Answer / bhupendra tomar

through cl we can find through RTVJOBA cmd.
but in case of RPG i don't know. if you have idea about RPG
then reply

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More RPG400 Interview Questions

How do you call procedures in ILE?

3 Answers  


RETRIVING DELETED RECORDS :- I'm frequently asked how to retrieve deleted records from an unjournaled physical file when the deleted records have not yet been removed from the file. Utility UNDEL lets you undelete records in a physical file. This public domain program is available in CISC and RISC versions, and the complete source code is available for download at: UNDEL for AS/400 Save File (RISC): http://www.as400network.com/sharewarefiles/undelris.zip UNDEL for AS/400 Save File (CISC): http://www.as400network.com/sharewarefiles/undel.zip UNDEL for AS/400 Save File (Source code): http://www.as400network.com/sharewarefiles/undelsrc.zip The utility takes advantage of the fact that deleted records in physical files are only flagged as deleted, and the record data still exists until it is overwritten or the file is reorganized with a utility such as RGZPFM. UNDEL simply reads the deleted record, then reuses the record by writing over it with the new record (thus eliminating the flag for the deleted record). Some homegrown and commercial utilities copy the file containing undeleted records to a save file, then use a program to read the save file, which contains live and undeleted records, to a file to undelete the records. The UNDEL utility is superior to the SAVF technique because there's no need to copy the file to a save file, which is especially important for really large files. When run, UNDEL displays the physical file records in their unformatted, raw text form. You can either position the display to a given relative record number or use F19 or F20 to find the previous and next deleted record, respectively. The utility also includes online help, which is almost unheard of for free utilities. Other utilities include the ability to undelete records. You can use the RTVDLTRCD command in the old QUSRTOOL (no longer supported by IBM). QUSRTOOL is now a commercial product called TAA Productivity Tools ( http://www.taatool.com ). The free file editor WRKDBF has a built-in undelete capability ( http://www.wrkdbf.com ), and several commercial file editors can undelete records. For a complete list of file editors, go to http://www.sourcebook400.com, select "Programmer Tools" under "Product Category," then select "File Editors."

0 Answers  


1.How to load Records of a Physical file(PF) in the reverse order, in CL program?

2 Answers   Cap Gemini,


can we use cl programming to update or delete physical files

12 Answers  


To check the locks , we use cmd WRKOBJLCK , but how we confirm whether it's objeck lock / member lock. I confused with the Lock type and Status values...Can any body please tell me ...

5 Answers  






1.Load an runtime array of length 99 from the pf and you want to handle all the possible errors?

0 Answers   HCL,


What is the Record Address file. How can we use it in RPG program?

4 Answers  


Assume 2 users are using the same file and first user updates some record in the file. Will the 2nd user will be able to see the updated record or not?

0 Answers  


Some times While checking MSGW for object / member / record locks ,I have seen it's locked by itself ...? How it happen and what action we need to perform if job is updating / writing a record....?

6 Answers   HSBC,


how to change the length of the field in a physicalfile?

12 Answers  


what is program status data structure?

1 Answers   IBM,


Suppose we have 10 records with same name and we are reading using READE,after 4 record i have to use CHAIN what is the output

3 Answers  


Categories