• No se han encontrado resultados

DISTRIBUCIÓN DEL ALUMNADO EN LAS AULAS Y EN LOS ESPACIOS COMUNES

In document PROTOCOLO DE ACTUACIÓN COVID-19 (página 29-35)

HORARIO DE ENTRADAS Y SALIDAS

6. DISTRIBUCIÓN DEL ALUMNADO EN LAS AULAS Y EN LOS ESPACIOS COMUNES

1. What is the maximum number of files which can be declared in CLP? ©

a) 3 b) 2 c) 1

d) No limit

2. Which of the following commands cannot be used on the command line? (a) a) RTVDTAARA

b) CRTDTAARA c) CHGDTAARA d) All the above

3. What is the command used to find all logical files based on one physical file? (a) a) DSPDBR

b) DSPOBJD c) DSPPFM d) a and b

4. What does the command FNDSTRPDM do? (b) a) Searches for the member in source physical file

b) Searches for particular string in a member or file c) Searches for objects in a library

d) None

5. Which is the command used to find the access path of a file? (b) a) DSPFFD

b) DSPFD c) DSPOBJD d) All the above

6. Which of the following combination of files can be declared in CLP? © a) Printer file, Database file

b) Display subfile, Message subfile c) Message subfile, Database file d) Database file, Display subfile

7. What is the function of DSPPGMREF? (b) a) Displays list of all files referred in the program

b) Displays the list of all objects used in the program c) Displays all copy books used in the program

d) Displays list of all call programs used in the program

8. What is the command used to delete program object? (b) a) DLTOBJ

b) DLTPGM c) DLTF

d) All the above

9. Which is the command to retrieve system date? (a) a) RTVSYSVAL

b) RTVJOBA c) RTVJOBD d) a and b

10. Which of the following files can be used in the TOFILE parameter of CPYF? © a) Logical file

b) Join Logical file c) Tape file

d) None of the above

11. Following method is used to load the messages in Message subfile (a) a) Load All

b) Expanding

c) Single Page(Equal subfile) d) None

a) CRTMSGF b) DSPMSGF c) WRKMSGF d) None

13. To which queue will you send messages? (a)

a) PGMQ b) MSGQ c) External MSGQ d) None

14. Which of the following is not true for CL programming? © a) CL programs are flexible

b) CL programs can be tested and debugged c) Cannot add or update records in data base files d) All the above

15. What is the command used to change the value of a data area? © a) DSPDTAARA

b) RTVDTAARA c) CHGDTAARA d) None

Answer the following briefly:

1. Name three CL commands which cannot be used on the command line.

2. What is the difference between program level and command level MONMSG? 3. What is the use of TFRCTL command?

4. What is the use of CALL command?

5. What is the difference between TFRCTL and CALL commands?

6. Can you create a Local Data Area? Is Local Data Area (*LDA) specific to a JOB?

7. How can the data be shared across different jobs? 8. Differentiate between data base files and data areas.

9. List out the advantages of data areas. 10. What are the different types of data areas? 11. What are the different Override commands? 12. How do you access all the members on a PF? 13. What is the function of RCLRSC command?

14. What is the CL command to display the record of display file?

15. What is the command used in CLP to read records from the database file? 16. What is DDMF? How do you create, change and display DDMF?(4marks) 17. How do you use a numeric database field in OPNQRYF?

18. How do you compile RPG program having compile time override?

19. Write program to find the number of members in a source file and store the names of members in

20. Write a program to add records in physical file from first member to second member without using

CPYF statement and find the record number difference if any.

21. Can a CL use Subfile?(MSGSFL)

22. How many record formats can you specify for a display file in a CL program?

DCLF command description:

Record format (RCDFMT)

Specifies the names of one or more record formats contained in the file. These record formats are used by the Send File (SNDF), Receive File (RCVF), and Send/Receive File (SNDRCVF) commands in the CL procedure. Database files can be processed only by RCVF. CL variable names cannot be specified in RCDFMT; only names of record formats can be used. For every field and indicator in each record format specified in RCDFMT, one CL variable is automatically declared in the program.

Note: A physical file can contain only one record format. A logical file which has multiple record formats defined in DDS may be used if it is defined over only one physical file member. If the physical file contains more than one record format, an error message is sent and the compile procedure fails.

Single values

*ALL

Every record format in the file, up to a maximum of 99, is to have its fields declared in the CL program as variables. If there are more than 99 record formats in the file, only the first 99 are used.

Other values (up to 50 repetitions)

name

Specify the name of the file record format whose fields are to be declared as variables in the CL procedure. CL variables cannot be used to specify the names.

23. How many number of files can you declare in a CL program? 1

For a CLLE program, it’s 5

24. What is wrong in the following program:

PGM

MONMSG CPF0000 DCLF FILE(INPUT) ENDPGM

Monmsg should be after DCLF statement

25. How to extract a word “hello” from the string “hello world”?

26. What is the command used to add members to a physical file? ADDPFM

27. What is the command used to read a record from the database or display file? RCVF 28. How do you know the keys used in a physical file without using SEU? DSPFD

29. How do you know the field attributes used in database file without using SEU? DSPFFD 30. How do you know the logical files based on a particular physical file? DSPDBR

31. What is the function of DSPPGMREF?

32. How to find the number of records in a physical file? DSPFD 33. How to copy a spool file to a database file? CPYSPLF

34. How do you execute system/38 commands?

35. Which has the highest priority if you give both program level MONMSG and command level

MONMSG? Program Level

36. How to find the system date in CLP? Rtvsysval qdate 37. How can you compress objects? Why? Cprobj (dcpobj) 38. How to use multiple files in CLP? Thru overrides 39. How to view overrides present on a file? dspovr

41. Describe how to handle error exceptions in a CLP. monmsg

42. Explain the function of SNDRCVF. Equivalent to EXFMT in RPG for display files 43. What is the function of ENDRQS command?

The End Request (ENDRQS) command ends (cancels) a previously requested operation (command). One common use of the End Request (ENDRQS) command is to cancel a request that is currently stopped at a breakpoint. This command function is also available as an option on the System Request menu.

44. What is a library list?

45. List the components of a library list. System, production, current, user 46. If &var1 = ‘---hello----‘ &var2 = ‘world’

result of the following operations (Interpret - as blank in the above variable) &var1 *cat &var2 ---hello----world

&var1 *tcat &var2 ---helloworld &var1 *bcat &var2 ---hello world

47. What is the command to delete a display file and a printer file? DLTF

48. Suppose FILEA contains two fields: NUM(numeric) and NAME(character). Write an OPNQRYF

command to sort the FILEA on NAME and take the records which have NUM greater than 10.

49. How to create a physical file with records generated in the above OPNQRYF? CPYFRMQRYF 50. How to find the member name, source file and library from which an object is created? DSPOBJD

*SERVICE

51. Explain the difference between ordinary subfile and message subfile.

52. What are the mandatory keywords used for DDS coding of a message subfile? SFLMSGKEY

SFLPGMQ SFLMSGRCD

53. We will give SFLPGMQ value as 10 or 276. Explain in which cases these values will be used.

SFLPGMQ (Subfile Program Message Queue) keyword for display files

Use this field-level keyword on the second (and last) field in the subfile record format for a message subfile. This field contains the name of the program message queue used by the OS/400 program to build a message subfile. In addition, SFLPGMQ can be specified on the subfile control record format when the SFLINZ keyword is specified on the subfile control record format.

The format of the keyword is:

SFLPGMQ([10] | [276])

When 10 is specified, SFLPGMQ generates a 10-byte field. 10 is the default. When 276 is specified, SFLPGMQ generates a 276-byte field.

This field is predefined as a character data type, hidden field. The following rules apply:

• The field name and the SFLPGMQ keyword and parameters are the only DDS you can specify for this field.

• If the name of the program message queue placed in this field at processing time is less than the field length (10 or 276 bytes), it must be left-adjusted and padded with blanks.

For Integrated Language Environment* (ILE*) programs using the 276-byte parameter value, the format of the field data must be as follows:

• The first 256 bytes contains the ILE call message queue name. The call message queue name is the same as the ILE procedure name. The name must be left-adjusted and padded with blanks.

• Bytes 257 through 266 will optionally contain the ILE module name. The name, when specified, must be left-adjusted and padded with blanks. If no module name is provided, these bytes must be set to blanks.

• Bytes 267 through 276 will optionally contain the name of the ILE bound program name. The name, when specified, must be left- adjusted and padded with blanks. If no bound program name is provided, these bytes must be set to blanks.

1. If a parameter value of 10 is used on SFLPGMQ and an ILE procedure name longer than 10 bytes is placed into this field at processing time, the procedure name is truncated to 10 bytes. The results will be unpredictable.

2. If a parameter value of 276 is used on SFLPGMQ and a program message queue name is placed into this field at processing time, bytes 257 through 276 must be set to blanks. If these bytes are not blank, the system assumes that a call message queue name has been given and will not find the specified program message queue.

• If the SFLPGMQ keyword is specified on both the subfile and subfile control record, the SFLPGMQ parameter values must match. However, different subfiles within the same file can use different SFLPGMQ parameter values.

This field is required on the subfile record format (identified by the SFL keyword) to build the subfile one message at a time through multiple output operations to the subfile record format.

You can also specify this field on the subfile control record format (identified by the SFLCTL keyword) to build the subfile all at once through a single output operation to the subfile control record. Specify option indicators with the SFLINZ keyword to control the way the subfile is built.

Multiple output operation:

If you specify the field name and SFLPGMQ on the subfile record, you build the subfile one message at a time with separate output operations to the subfile record format. For each output operation, the message reference key must be in the first field of the record (SFLMSGKEY keyword), and the name of the program message queue must be in the second field. At the time of the output operation, the OS/400 program retrieves the identified message from the queue and places it in the subfile as a record.

Note:

A CL program cannot be used for a multiple output operation. The relative record number required each time a message is built is not supported for CL.

Single output operation:

If you specify SFLPGMQ (with its named field) and the SFLINZ keyword on the subfile control record format, you build the entire subfile with one output operation directed to the subfile control record format. On the output operation, the OS/400 program initializes the subfile with all messages that are on the program message queue whose name is in the SFLPGMQ field. If necessary, the OS/400 program extends the subfile to contain all messages on the queue. For this function, the SFLMSGRCD, SFLMSGKEY, and SFLPGMQ keywords must be specified with the subfile record format (SFL keyword). The SFLPGMQ and SFLMSGKEY keywords are ignored for this function and your program need not set the values of their fields.

Special value:

The SFLPGMQ field can contain a special value, * (asterisk), instead of a program message queue name. If the

program moves an asterisk to the SFLPGMQ field, the OS/400 program uses the message queue of the program issuing the output operation. You cannot use an asterisk if your program is a CL program.

Both multiple and single output operations:

If you specify SFLPGMQ with both the subfile record format and subfile control record format, you can use the single operation function one time and the multiple operation function some other time. Do this by setting indicators before issuing the output operation; however, all operations to a particular subfile must be consistent (multiple or single, but not intermixed) when preparing for a single display of the subfile.

Option indicators and display size condition names are not valid for this keyword

54. Which Function key is used to do step by step debugging? F10 (for STRDBG) 55. How you will find particular string/word ?

56. Which function key is used to add break points? F6 57. Which function key is used to remove break points? 58. How to display the value of a variable? F11

59. What is the command used to start the debug? STRDBG

60. How to run the program up to a particular point skipping in between statements? F12 61. How to change the value of a variable?

62. How to enter a system command? 63. How do you start source debugger?

65. To which queue will you send messages?

66. How will you clear the messages from message queue?

67. In DDS coding for Message subfile, will you need SFLCLR keyword? 68. What is the default value for SFLPAG in Message subfile?

69. Is controlling indicators necessary for mandatory keywords(Except for SFLEND Keyword)

that will be given in DDS coding.

70. Which API is used to send the messages?

71. Which API is used to clear the messages from program Q? 72. How do you start source debugger?

73. How can we rename an object? 74. What are data queues?

75. What are message queues?

76. What is an Open Data Path (ODP)?

77. Compare and contrast Open Query File and Logical Files.

78. List out the various steps involved in a typical Open Query File. 79. What are the types of joins supported by OPNRYF?

80. What is the function of the POSDBF command? 81. What is the function of CPYFRMQRYF?

82. How can we find the number of records present in a file without using SEU? 83. What is a break point?

84. Change the value of data area MYDAT using a CL program.

State whether true or false:

1. Two objects with same name and type cannot exist in different libraries. (F) 2. Not all commands typed on command line are CL commands . (F)

3. A CL command can be an IBM or user defined command. (T) 4. DCLF is used to declare a display or database file in CL. (T)

5. All variables in the file being declared gets implicitly defined in the CL program. (T) 6. CL command is a statement that requests the system to perform a function. (T)

7. The built-in menu called MAJOR organizes all the AS/400 commands. (T) 8. RCVF reads a record from a display or data base file. (T)

9. SNDF writes a record to a display or a data base file. (F)

10. OVRDBF is used to qualify the library where the file is located. (T)

11. The submit job command is used to submit a job to a job queue for interactive processing. (F) 12. A message subfile is a repository of all the predefined messages. (F)

13. A library is an object used to group related objects. (T)

14. The declare commands (DCL & DCLF) must precede all other CL statements. (T) 15. A CL program can contain only CL commands. (T)

16. Program variables are stored in libraries. (F)

17. The value of a CL variable can be changed using CHGVAR. (T)

18. The CHGVAR command can be used to retrieve and to change the LDA. (T) 19. The current library cannot be a duplicate of any library in the library list. (F) 20. We should not create a library with a name that begins with Q. (T)

21. *CHANGE (change authority) allows the user to access the objects in the library. (T)

23. The GOTO command processes a conditional branch. (F) 24. The DO command repeats a group of commands. (F)

25. Embedded IF commands are permitted up to 12 levels, in CL programming. (F)

26. The MONMSG command is used to monitor for escape, notify, or status messages sent to its

program queue. (T)

27. CVTDAT command is used to change the format of the date in a CL program. (T)

28. The name of the user who called the program can be retrieved using RTVUSRPRF command. (T) 29. When the TFRCTL command is used, control returns to the program containing the TFRCTL

command. (F)

30. The RETURN command in a program removes that program from the program stack. (T) 31. Using CALL command, a maximum of 40 parameters can be passed to the called program. (T) 32. The TFRCTL command cannot be used to pass parameters to the program being called. (F) 33. Data queues are similar to message queues. (T)

34. A data area is an object used to hold data for access by any job running on the system. (T) 35. The Local Data Area cannot be referred to from any other job. (T)

36. The data area cannot be locked for a single user. (F) 37. You can create, delete, or allocate a local data area. (F) 38. Library list is an object. (F)

39. No library is associated with the local data area. (T)

40. LDA can be used to pass information to a subprogram without the use of a parameter list. (T) 41. The system creates a group data area when an interactive job becomes a group job. (T)

42. Only one group data area can exist for a group. (T)

43. A group data area can be referred to by jobs outside the group. (F)

44. The group data area is deleted when the last job in the group is ended. (T) 45. You cannot create, delete, or allocate a group data area. (T)

46. QTEMP is associated with the group data area. (F)

47. A PIP data area is created for each prestart job when the job is started. (T)

48. The CRTDTAARA command uses *SHRUPD (shared for update) lock on the data area during the

command processing. (F)

49. The CHGDTAARA does not change the attributes other than its value, for a data area. (T) 50. For a running job, you cannot add entries nor remove entries from the library list. (F)

51. The current library for a job can be changed using CHGCURLIB or CHGLIBL commands. (T) 52. The libraries in a library list may not be existing on the system. (F)

53. If no library is specified while creating an object, it is placed in QGPL. (F) 54. Only display files with a single record format can be used by a CL program. (F) 55. Display files can have a maximum of 99 record formats. (T)

56. Communication on AS/400 system occurs through messages. (T)

57. System messages are stored in the file QCPFMSG in the library QSYS. (T)

58. SNDPGMMSG command allows us to send messages to a workstation user or the system operator.

(F)

59. RMVMSGQ command removes a message from a message queue. (F)

60. MONMSG monitors for escape, notify, and status messages that are sent to a program’s message

queue. (T)

61. The MRGMSGF command can be used to copy message descriptions from one message file to

another. (T)

63. A break-handling program is called whenever a message of high severity arrives on the message

queue. (T)

64. Program message queues are used to send messages between program calls of a job. (T)

In document PROTOCOLO DE ACTUACIÓN COVID-19 (página 29-35)