You are on page 1of 40

What is DDM ?

Distributed Data Management is a function of the OS/400 that allows an application program or user on one system to use database files stored on remote system.

What are the facilities a ailable on !S/400 for self"learning? on"line education# $%! Database and &elp.

What is an Ob'ect? !n ob'ect is any thing that e(ist in and occupies space in storage and on which operation can be performed.

What are the different types of Ob'ects a ailable in the !S/400? )ibraries# *olders# *iles# +rograms# ,ombined definitions# $ueues# -ser +rofiles.

&ow are the ob'ects stored in !S/400? !ll ob'ects are stored on !S/400 in a single le el storage. .n this method all ob'ects are referenced by one irtual address which is translated into a physical address whether it is an au(iliary storage or main memory.

What is a library in !S/400? ! library in !S/400 is an ob'ect that ser es as a repository for other ob'ects.

/ame few .0M supplied libraries? $1+)# $23M+# $-S42OO)# $S5S# $4+1 % $,0).

What is a library list? ! list that indicates libraries used for the process and the order in which it has to be searched. System identifies it in 6).0).

&ow many libraries can be there in a library list? 2otal 40 789 system and :9 application;.

Where is the system part of the library list stored? .n S5S<!) 7$S5S).0);

What is a *older? ! *older is a named ob'ect that is used as a directory for documents and other folders. *olders can be filed with in another folder.

What are the different !pplication De elopment 2ools a ailable on !S/400? S3-# 4)-# +DM# SD!# $-345

What are the le els of security on !S/400? 80#:0#=0#40#90

What is error se erity? 3rror se erity determines the le el of se erity that is re>uired to terminate the 'ob.

What is a -ser +rofile? What are the arious classes? -ser profile is an ob'ect which identifies a user to the system. .t contains user name# +assword# Owned ob'ects# !uthori?ed ob'ects# Scheduling priority# Special authority# .nitial program @ob description. Security officer# +rogrammer# WorAstation# System operator# +rogrammer ser ices 4ep % ,ustomer engineer.

What is 1roup +rofile? .t is similar to -ser +rofile# but the attributes specified is applicable to an entire group.

What are the different types of >ueues in !S/400? @ob >ueue# Message >ueue# Output >ueue# Data >ueue.

What are @ob$ and +rint$ ? @ob$ B !n ob'ect that contains a list of batch 'obs waiting to be processed by the system. +rint$B !n ob'ect that contains a list of spool files to be written to a printer de ice.

What is a Spool file? Why is it re>uired? ! file that holds output data to be processed# such as information waiting to be printed.

What is a @ob? What are the attributes of a 'ob? ! 'ob is the basic unit of worA on !S/400 2he attributes areB @ob /umberB -ni>ue system generated se>uential number @ob /ame B !ny user defined name 7Ma(. 80 char; -ser /ameB Who initiated the 'ob?

What is 'ob description? ! 'ob description defines the en ironment in which a batch/interacti e 'ob is to be e(ecuted.

What is the difference between .nteracti e % 0atch 'ob? .nteracti e @obB @ob started for a person who signon to a worAstation. 0atch @obB ! predefined group of processing actions submitted to the system to be performed.

What is a 1roup @ob? 1roup @ob is attached to one worAstation and a user. 2here should be an initial group 'ob and it can be branched to many other group 'obs. 2he group 'obs can ha e different library lists and different output# message >ueues. 1roup @ob is useful in enhancing the programmerCs producti ity. .t is as though logging into the same user"id many times.

What are the two main attributes which go ern the e(ecution of a 'ob? 4un time priority and 2ime slice.

What is a sub"system? Sub"Systems are specific user defined partitions of the ,+- where arious 'obs may be e(ecuted. One subsystem can ha e more than one acti e 'ob at a time.

What is a de ice file? ! de ice file contains the description of how data is to be presented to a program from a de ice or ice ersa. De ice file can be +rinter# DisA# 2ape or 4emote system.

What is an .,* file? ! de ice file that allows a program on the system to communicate with program in other system.

What is a message file? .t is a file which contains the messages of an application. *or e(ample all 4+1/400 messages are stored in a fileD all ,O0O)/400 messages are stored in a file.

What is a 'ob log? ! record of re>uest submitted to system is a 'ob. 2he message related to the re>uests# and the action performed by the system on the log. .t is maintained by the system program

What is the purpose of O+/$45* 7Open $uery *ile;? O+/$45* is used to select certain records of the database file based on the $45S)2 7$uery select; condition.

&ow do you create files dynamically without DDS? through O+/$45.

What command must be e(ecuted before e(ecuting O+/$45* command? O<4D0*.

What is a data area? ! data area is an ob'ect used to hold data for access by any 'ob running on the system. ! data area can be locAed to a single user# thus pre enting other users from processing at the same time.

What are the types of data areas? -ser defined Data !rea# )ocal Data !rea 7)D!;# 1roup Data !rea 71D!;# and +rogram .nitiali?ation +arameter 7+.+; Data !rea.

What is )D!? !n )D! is created by the system for each 'ob in the system# including autostart 'obs# 'obs started on the system by a reader# and subsystem monitor 'obs.

What is the type and length of an )D!? 6,&!4# 80:4 bytes.

What is 1D!? !S400 system creates a 1D! when an interacti e 'ob becomes group 'obs. Only one

1D! can e(ist for a group.

&ow can you create a user defined data area? -sing ,42D2!!4! command.

What are the different ways to input data into a data area? ,&1D2!!4! 7using ,); -sing O-2 opcode in 4+1

&ow do you retrie e data from data area? -sing 42<D2!!4! command in ,) -sing ./ opcode in 4+1.

What are the alid user defined data area types? ,&!4# /-M!4., and )O1.,!).

&ow can a data area are locAed after being updated? -sing O-2 6)O,E.

what is the use of data >ueues? Data >ueue is a type of system ob'ect that you can create. Data >ueues are used in program to program communication.

&ow do you create data >ueues? -sing ,42D2!$ command.

What are the alid data types for a data >ueue? ,har# /umeric# and )ogical.

What are the two types of read performed on data >ueues ? 4ead with locA# and read without locA.

&ow do you use D30-1 utility ? S24D01 program"name -+D+4OD7653S;

What is an authori?ation list ? ! list of two or more user .ds % their authorities for system resources. 2he system identifies it as an ob'ect type 6!-2).

&ow do you grant authority for an ob'ect? -sing 142O0@!-2 command.

What are the types of ob'ect authorities ? 6-S3# 6,&!/13# 6!))# 63F,)-D3# 6!-2)# 6O0@3F.S2# 6O0@M12# 6O0@O+4# 6!DD# 6D)2# 643!D# 6-+D.

&ow do you e(ecute 'obs in batch mode? S0M@O0

What is the use of O<4D0* ? 5ou can use the O erride with Database file 7O<4D0*; command to replace the database file named in a ,) program or to change certain parameters of the e(isting database file.

What is the use of O<4+42* ? O erride with +rinter file 7O<4+42*; command is used to o erride certain parameters of

the printer files used in the program or to replace the printer file.

&ow do you change file attributes such as si?e# file wait time# record wait time etc.# permanently ? -sing ,&1+* command.

What is the purpose of ,42,MD ? 2o create user defined command.

What is class of ser ice ? ! set of linA and node characteristics associated with a session.

&ow to see acti e 'obs of the system ? -sing W4E!,2@O0 command.

&ow do you detect unused spool storage ? -sing 4eclaim Spool Storage.

What are the functions of 4emote @ob 3ntry 74@3; ? !llows user of !S/400 system to submit 'obs and recei e 'obs from a host system.

What is the function of 4@3 ,on ersion -tility ? .t con erts compressed data written to an !S/400 database file to decompressed data written to another !S/400 database# disAette# or de ice file.

What is the function of the S0M4@3@O0 command? Sends 4@3 input stream to host system.

What is 'ournaling and commitment control? @ournaling is a function which records the changes in a file in a 'ournal. 2hese record images are used to reco er the changes in the file should the system ends abnormally. ,ommitment control is a function that allows you to define and process a no of changes to database files as a single unit 7transaction;.

What is the purpose of S24,M2,2) command ? Starts commitment control for files that are being 'ournal led.

What are the system ob'ects re>uired for 'ournaling? @ournal recei er# 'ournal and +*s to be 'ournal led.

What is ,+* ? ,ontrol +rogram *acility 7,+*; is an operating system on S/=G.

What is in ocation stacA ? )ist of programs maintained by the system as one program calls another in a series of calls within a single tasA or 'ob.

What is time slice ? ! finite amount of time in which a 'ob is granted system resources while other 'obs are >ueued.

What is .+) ? .nitial +rogram )oading 7.+); is run by OS/400 when the system is started.

What does <:4:M0 mean ?

<er. :# 4elease : % Modification le el 0. 2his refers to the ersion of OS/400.

/ame the commands used to duplicate a file? ,+5* " ,opy *ile % ,42D-+O0@ " ,reate Duplicate Ob'ect.

/ame the command for changing the attributes of a spool file? ,&1S+)*! " ,hange Spool file !ttributes.

/ame the command which gi es the attributes of a 'ob ? 42<@O0! " 4etrie e @ob !ttributes.

What is the function of +DM ? +roducti ity tool for copying# deleting# scanning# changing % creating source files.

What is the function of S3- ? ! utility for editing programming language source code.

D!2!0!S3 *.)3S What are the different definition le els in Data Description specifications ? *ile le el# 4ecord le el# *ield le el# @oin le el# Eeyfield le el# Select/Omit le el.

What is difference between Source +hysical *ile and +hysical *ile ? ! Source +hysical *ile contains the source for the arious ob'ectscreated. 2his file has a specific structure. ! +hysical *ile contains data# and the record format can be different for different physical files.

What is the difference between +hysical and )ogical files ? +hysical file contains data# where as )ogical file ser es as a access path to database.

What is an access path ? 2he order in which the database fields are organi?ed for processing in the program.

What are all the different types of access paths ? !rri al se>uence access path# Eeyed se>uence access path.

&ow many record formats can you ha e in a +hysical file and in a )ogical file ? +hysical file can contain only one record format# )ogical file can contain more than one record format.

What is a field reference file ? ! field reference file is a physical file which contains no data# contains field description. this is used as a reference file by other physical files.

What is the default alue for the number of increments for the physicalfile ? 2hree.

When is the D*2 Aeyword in +* used for? 2o specify the default alue it a field.

What is Multi"format logical file ? )ogical which uses fields from two or more physical files.

What is dynamic select ? Selection and omission of )* records performed during processing# instead of access path is maintained. 2his can be used when Aey access path does not e(ist.

What is the Select and Omit criteria in logical file ? 2his is used to specify rules for the Selection/Omission of records from a +hysical *ile.

,an fields be concatenated at the logical file le el ? 5es# by using ,O/,!2 Aeyword.

When would the !)) Aeyword be used ? -se with Select or Omit# to select/omit records.

What is a @oin )ogical *ile# ,an it be used for -pdate ? )ogical file that combines more than one physical file.-pdate is not possible through @)*.

&ow many files can be 'oined at a time# What is the ma(. no. of files ? !t a time you can 'oin two files. 2he ma(. no. of files is =:.Only one primary file and the remaining are secondary files# 2he primary file and at least one secondary file must be physical files.

.s it possible to 'oin the same file to itself ? 5es.

What is *,*O# *.*O# ).*O in Database en ironment ?

2hese are file le el Aeywords which are used to access the records in the order *,*O B *irst ,hanged *irst Out *.*O B *irst .n *irst Out ).*O B )ast .n *ist Out

.f a file layout is changed# how do you generate new +* and retain data? ,opy the file and change the structure of +hysical file# later copy old file with drop option.

What is the o erhead on logical file ? &ow can it be impro ed ? Maintaining access path and storage space. We can impro e the performance by using 6D3)!53D# 6430-.)D Aeywords to enhance the speed.

&ow can the sign of a numeric be ignored when se>uencing a logical file ? 0y specifying the record le el Aeyword -/S.1/3D.

.f a field references a field that has an 3D2,D3 or an 3D2W4D Aeyword specified# can the 3D2,D3 or 3D2W4D from the referenced field ignored ? 5es# by using D)23D2 Aeyword.

What does the Aeyword -/.$-3 mean ? 4ecords with duplicate Aey alues are not allowed.

State three different methods of maintaining access paths ? .mmediate# 4ebuild % Delay.

D.S+)!5 *.)3S

What are the different types of Aeywords in display files ? *ile le el# 4ecord format le el# *ield le el.

What is the ma(imum number of records you can specify in a display file ? 80:4.

&ow can a screen field that has changed since the last output operation be detected ? !ttach the MD2 attribute to the field# to detect whether field has been changed as a result of user input.

What would be the effect on the field where re erse image# underline and highlight display attributes are acti e ? 2he result is same as if you had specified /D.

What is the use of DS+!247MD2; Aeyword ? Sets on the modified Data 2ag of the field. 2his Data 2ag detects whether the field has been changed as a result of user input.

.f DS+!247+,; and ,S4)O, were specified for a format# which Aeyword would ha e priority ? ,S4)O, gains priority.

,an error messages as a result of a ,OM+# 4!/13 or <!)-3S Aeyword be o erridden ?

5es# through ,&EMS1.D Aeyword.

What is the purpose of O<4D2! and O<4!2! Aeywords ? O<4D2! Aeyword 7field or record le el; can be used to o erride the e(isting data contents of a field or record already on the display. O<4!2! Aeyword 7field or record le el; can be used to o erride the e(isting display attributes of a field or record already on the display.

&ow can a message from a message file appear as a constant on the screen ? 0y using MS1,O/ 7message constant; Aeyword.

.n con'unction with what other Aeyword must O<4D2! and O<4!2! be used ? +-2O<4 Aeyword must be used.

&ow can a field that is larger than what could fit onto one line be truncated from the last blanA rather than from the last character position? -sing 0)E*O)D Aeyword.

What is the purpose of the ./D!4! Aeyword ? 2his *ile"le el Aeyword is used to remo e option and response indicators from the buffer and places them in HH"byte separate indicator area.

3(plain the purpose of E33+ and !SS-M3 Aeywords ? E33+ B Eeep the display from being deleted when the display file is closed. !SS-M3 B .t is used to specify that the OS/400 program is to assume that this record is already shown on the display when this file is opened.

3(plain the use of D*4W42 display Aeyword ?

/o records will be displayed until there is an ./O operation.

What is the purpose of *4,D2! Aeyword ? .mmediately display a record format without waiting for the ne(t ./O operation.

What Aeyword must be used with +4O23,2 Aeyword ? O<34)!5

Where is the ariable for the S)/O76<!4; Aeyword be defined ? !t run time before displaying the record format.

-nder what conditions would a field where the 344MS1 Aeyword was acti e would not be displayed in re erse image ? .f it is an output"only field or input capable field with display attributes -)# &. are acti e.

When will the message for field that has the 344MS1 Aeyword acti e not be displayed ? .f more than one 344MS1 Aeywords are acti e then the first will be acti e# because only one error message will be displayed at a time.

What is ,&1./+D*2 Aeyword# and what will be the effect if you define this Aeyword at file with out any parameter alues ? 2his file# record or field le el Aeyword is used to change one or more input defaults for input capable fields. .f you define this Aeyword at file le el without any parameter then the underline will be suppressed.

.n what case control will be passed bacA to the program when the last character of the field is Aeyed ? ,&3,E734; 34 " 3nd of 4ecord.

S-0*.)3S What is a subfile ? Subfile is a group of records of same record format and can be read from or write to the display in a single operation.

What are the contents of subfile ? Subfile 4ecord *ormat# Subfile ,ontrol 4ecord *ormat# 4elati e 4ecord /umber# Subfile 4ecord /umber# !ssociated Subfile Eeywords.

What are the two record formats that a subfile contains ? Subfile record format7S*);# and subfile control record format7S*),2);.

What is S*)+!1 and S*)S.I ? S*)+!1 B it is an attribute which specifies the number of records that can be displayed in a screen. S*)S.I B it is an attribute which specifies the number of records can be stored in the subfile.

What is the ma(imum number of subfiles that can specified in a display file ? 98:

2he ma(imum number of subfiles that can defined in a 4+1 program for one display file is JJJ . :4

2he ma(imum number of subfiles that can be acti e for a single file isJJJJ . 8:

What are the different opcodes used for file operation on a subfile in a 4+1 +rogram ? 43!D# 43!D,# ,&!./#-+D!2 and W4.23

,an more than one subfile record be displayed on one line ? 5es# by using S*))./ Aeyword.

&ow do you specify the number of records to roll in a subfile ? -se S*)4O)<!) Aeyword in DDS along with the number# which specifies the number of records to scroll at a time.

&ow will you display a particular page in subfile ? Mo e a alid relati e record number744/; in the field specified using S*)4,D/04 Aeyword in DDS.

&ow to picA up the changed records e ery time in a subfile after the first change made ? Seton S*)/F2,&1 Aeyword indicator and update the subfile record.

What is the use of the S*)3/D Aeyword ? 0y specifying this Aeyword# the 0ottom/More message could be displayed at end of screen.

&ow do you toggle between single line and multi"line display of a particular record in a subfile ? -sing S*)D4O+ Aeyword.

3(plain the difference between defining Subfile and Message"subfile ? ! subfile record is defined by S*) Aeyword# whereas a message subfile is defined by S*)MS1 Aeyword.

,an a single screen format occupy a screen area abo e and below a subfile format ? /ot possible.

&ow can a program be pre ented from failing o er when 43!D, is performed on an empty subfile ? ,hecA indicator placed in position )O# which will be seton if 3O* if reached.

,O/24O) )!/1-!13 7,)/400; &ow to start a ,) program ? +1M.

&ow many files can be declared in ,) ? One.

Which precedes# the file declaration or ariable declaration ? <ariable declaration and then *ile declaration.

What are the different types of ariables a ailable in ,) ? D3,# ,&!4# )1)

.n ,) +rogram K%K precedes JJJJ . <ariables.

&ow do you pass parameters in ,) ? -sing +!4M Aeyword.

,an libraries be added to the library list through ,) ? 5es# using !DD).0).

What is the difference between ,!2# 2,!2 and 0,!2 ? ,!2 B ,oncatenate two ariables or constants into one continuous string. 0,!2 B 2runcates all trailing blanAs in the first character string D one blanA is inserted # then the two character strings are concatenated. 2,!2 B 2runcates all trailing blanAs in the first character string# thetwo character strings are concatenated.

&ow do you end a ,) program ? 3/D+1M

What are the different types of messages in ,) ? .mmediate message# 0reaA message# +rogram message# -ser message.

&ow can errors be trapped in a ,) program? 0y using Monitor Message ,ommand 7 MO/MS1 ;

What is the ma(imum length of a ariable name in ,) ?

Ma(imum 88 characters 7including K%K;

What are the limitations of ,) 7compare to 4+1; ? 5ou cannot use ,) program to B . !DD or -+D!23 records in database files . -se +rinter or .,* files . -se +rogram described files . -se the concept of subfile 7to display more than one record;# but a single output message subfile is a special type of subfile that is supported well in ,) . -se subroutines. 5ou cannot declare more than one ob'ect 7file; in a ,) programme.

4+1/400 What is 4+1 ? 4eport +rogram 1enerator.

What are the positi e points of 4+1 )anguage ? ,ontains opcodes which maAes it fle(ible with OS/400 ,an access the e(ternally described file.

3(plain 4+1 +rogram )ogic ,ycle ?

When is it efficient to maAe use of 4+1 ,ycle ? When the file is arranged in se>uence and output is based on control breaA.

,an you call a program in your 4+1 program# which is coded in some other language? 5es# !ny program ob'ect a ailable on !S/400.

What are the different types of specification a ailable in 4+1/400 ? ,ontrol Spec.7 & ; *ile Spec.7 * ; 3(tension Spec.7 3 ; )ine counter Spec.7 ) ; .nput Spec.7 . ; ,alculation Spec.7 , ; Output Spec.7 O ;

.s it necessary to define all formats? Which are mandatory and which are Optional? /o# all are Optional.

What is the use of & spec. in 4+1 ? .t identifies by & in column L# +ro ides information about generating and running programs.

When will D-M+ and D30-1 opcodes be ignored ? .f blanA is specified in position 89 of & specs.

What are the alid file types 7 position 89 ; in * specification ? .7.nput file;. O 7Output file;. - 7-pdate file;.

, 7,ombined 7./O; file;.

Specify different indicators used in 4+1 ? O erflow indicators. 4ecord .dentifying .ndicators. *ield .ndicators. 4esulting .ndicators. ,ontrol )e el .ndicators.

What are ,ontrol le el indicators ? )8 to )H used to identify certain fields on control fields and then used to condition which operations are to be processed at detail or total calculation or output time.

What is the use of 3 specification in 4+1 ? 3(tension Specs describes all record address files# arrays and tables.

What is the use of ) specs in 4+1 ? )ine counter specification can be used to describe printer file to indicate the length of the form and number of lines per page.

.n which specification can a report layout be defined ? O Specification.

&ow many files can be defined in * specs ? ! ma(imum of 90 files.

&ow many printer files can be defined in * specs ?

! ma(imum of G files.

1i e three main purposes of *ile specification ? 2o define files# to describe the files# to assign the files to specified de ices.

&ow do you specify page o erflow indicator for printer files in 4+1 ? Specify an indicator in positions =="=4 of * specification.

What is a +rimary *ile ? .t is used in 4+1 +rogram ,ycle to automatically read records in a cycle.

,an an inde(ed file be accessed in arri al se>uence in 4+1 program ? 5es.

What is a program described file in 4+1 ? 2he field name and length of the fields are defined with in the 4+1 program.

What is an e(ternally described file ? !ll information about the fields is specified in DDS and the 4+1 program can use them with in the program.

,an you specify a display file to be used in the following modesB.nput# Output or ,ombined modes? 5es.

What are match fields indicators ? Matching record indicator is seton when all the matching fields in the record of a

secondary file matches with all the matching fields of a record in a primary file.

What is the length of a ariable in 4+1 ? L ,haracters.

What are the different arithmetic Opcodes ? !DD# S-0# M-)2# D.<# M<4# S$42# F*OO2# I"!DD# I"S-0.

When is a 2!1 statement used in 4+1 ? .t is used as a )abel.

What are the different Opcodes a ailable in 4+1 for Database access ? 43!D# ,&!./# W4.23# -+D!2# D3)32# S32))# S3212# 43!D3# 43!D+# 43D+3# O+3/# ,)OS3#*O4,3# /3F2# -/),E.

What is 43!D+ opcode ? 4ead pre ious record.

What is 43D+3 opcode ? 4ead +rior e>ual record.

&ow do you checA if a di ision was whole di ision ? ,hecA the 3$ indicator be set to K8K

What opcode could be used to test an alphanumeric field for all numeric alues? 23S2/.

What opcode will be used to test the ?one of a character field ? 23S2I.

&ow do you specify &alf !d'ust ? .t should be specified in the column 9= of , specs as K&K to indicate half ad'ust. .t will be effecti e only if the resultant alue is ha ing more decimals than the result field.

3(plain the difference between 43!D# ,&!./ and S32)) ? 43!D operation reads the record currently pointed to# from a full procedural file. ,&!./ operation retrie es a record from a full +rocedural file# sets a record identifying indicator O/ and places the data in the input fields. S32)) operation position a file at the ne(t record that has a Aey or relati e record number that is greater than or e>ual to the search argument specified. 2he file must be fully procedural for all three opcodes.

What does )O and 3$ indicators signify in 43!D# W4.23 and ,&!./ operations ? )O indicator specifies the error status on the abo e operations.3$ indicator specifies the 3O*# 4ecord not found.

&ow can database records be read without locA ? +ut K/K in position 9= of , specs.

What is the difference between MO<3 and MO<3) ? MO<3 operation will transfer characters from the factor : to the result field# the mo e starts from rightmost character of factor :.MO<3) operation will transfer characters from factor : to the result field# the mo e starts from leftmost character of factor :.

&ow do you concatenate two string ariables in 4+1 ?

-sing ,!2 opcode or with MO<3 followed by MO<3).

What are the string operations possible in 4+1/400 ? ,&3,E# ,&3E4# S-0S2# ,!2# F)!23# S,!/.

What does S-0S2 do ? 3(tracts a specified character string from a base character string.

What does ,&3,E opcode do ? 2he checA operation erifies that each character in the base string 7factor :; is among the character indicated in the comparator string7factor 8;.

$S808H8.n con'unction with which statements can O4(( and !/D(( conditions be used ? !S808H8 DO-((# DOW((# .*((# and W&((.

$S808H: What is the difference between DO- and DOW ? !S808H: DO- checAs after entering into the loop# it is performed at least once.DOW checA before entering into the loop.

$):08H= What is .234 and )3!<3 opcodes do ? !):08H= .234 transfers control from within a DO group to the 3/DDOstatement of the DO group. .t causes the ne(t iteration of the loop to be e(ecuted immediately )3!<3 operation transfers control from within a DO group to thestatement following the 3/DDO operation.

$):08H4 Which instructions support structured programming in 4+1 ?

!):08H4 !/D((# ,!S((# DO group# 3)S3# 3/Dyy# .*((# .234# )3!<3# O4((# O2&34# S3)3,# W&((.

$S808H9 What does KS4K in columns M"G of , specs mean ? !S808H9 ,alculation operation is a part of 4+1 subroutine.

$):08HL 3(plain ,!S((# and ,!0(( statements ? !):08HL ,!S(( operation allows you to conditionally select a subroutine for processing. 2he condition is based on the relationship between factor 8 and factor : as specified by ((..f the relationship is true the subroutine specified in the result field is processed.

,!0(( operation compares factor 8 with factor : # if the condition specified by (( is true# the program branches to the 2!1 operation associates with the label specified in the result field.

$)=08HM What is ,)3!4 and 43S32 ? !)=08HM,)3!4 operation sets the elements in a structure 7record format# array/table# data structure; or a ariable 7field# subfield or indicator; to ?ero # blanA or K0K depending on the field type 7numeric# character# indicator;

43S32 operation sets the elements in a structure 7record format# array/ table#data structure; or a ariable 7field# subfield or indicator; to its initial alue.

$)408HG What is S,!/ and F)!23 ? !)408HG S,!/ operation scans a character string 7base string; contained infactor : for a substring 7compare string; contained in factor 8.

F)!23 operation translates characters in source string 7factor :; to the from and to

strings7factor 8; and put into the result field.

$)408HH &ow do you use commitment control in 4+1 program ? !)408HH -sing ,OM.2 operation. MaAes all changes to the files that ha e been specified in output operation since the pre ious ,OM.2 or the beginning of operations under commitment control7if there has been no pre ious ,OM.2 or 4O)0E operation;.

$S=0:00 &ow do you use e(ceptional write in , specs ? !S=0:00 -sing 3F,+2 opcode.

$)=0:08 What does the opcode *433 do ? !)=0:08 2he *433 operation remo es a program from the list of acti ated programs# frees static storage and ensures program initiali?ation 7first cycle processing; the ne(t time program is called. .t does not close file or unlocA data area.

$S=0:0: What does opcode +OS2 do ? !S=0:0: +uts information in .*/DS.

$S:0:0= What is the difference between W4.23 and 3F*M2 of a display file ? !S:0:0= W4.23 displays a record format on worAstation# 3F*M2 displays and accepts from the worAstation.

$S:0:04 What is the difference between +).S2 and E).S2 ? !S:0:04+).S2 operation defines a uni>ue symbolic name for a parameter list to be specified in a ,!)) operation.

E).S2 is a declarati e operation that gi es a name to a list of Aey fields

$O=0:09 ,an you ha e multiple Aey lists for a single file ? !O=0:09 5es.

$S40:0L What are the different types of arrays a ailable in 4+1 ? !S40:0L +re"e(ecution time array. ,ompile time array. 3(ecution time array.

$)40:0M &ow do you specify data for a compile time array ? !)40:0M5ou can specify in 3 specs about the no of entries per record# no of elements# length of each element with the corresponding data entered at the end of the 4+1 program starting with 66.

$O=0:0G What is the ma(imum number of elements in an array ? !O=0:0G HHHH.

$O=0:0H ,an we define Multi"dimensional arrays in 4+1 ? !O=0:0H /o.

$S:0:80 What is F*OO2 opcode ? !S:0:80 !dds all the elements in a numeric array# and places the sum in the result field.

$S:0:88 &ow can we sort an array ? !S:0:88 0y using SO42! opcode.

$S:0:8: What is MO<3! opcode do ? !S:0:8: 2ransfer character to numeric alues from factor : to result field. MO<3! can be possible to !44!5"!44!5# !44!5"*.3)D# or *.3)D"!44!5.

$S:0:8= &ow to initiali?e an array ? !S:0:8= ,)3!4 or MO<3! 6blanAs to array.

$S:0:84 What is )OE-+ opcode do ? !S:0:84 )OE-+ opcode search for a particular element in an array / table.

$S:0:89 ,an )OE-+ operation be used for unsorted array? !S:0:89 5es.

$):0:8L What is the difference between an array and a table ? !):0:8L !n array elements can be referred by array name.3lements in array can be accessed by their position relati e to other elements.

2able name does not refer to the entire set of table elements. 3lements in a table can not be accessed by their position relati e to the other elements.

$O=0:8M What is the ma(imum length of a table name ? !O=0:8M L characters.

$O:0:8G What is the synta( of a table name ? !O:0:8G 2able name should start with 2!0.

$S=0:8H &ow can the user implicitly open and close the files in 4+1 program ? !S=0:8H 3nter -, in position M8"M: of * specs.-se O+3/ and ,)OS3 opcodes in 4+1 program to open and close files.

$O:0::0 During input operation which indicator position is seton if there is a record locA? !O:0::0 )O indicator position is seton.

$S:0::8 What is the significance of D3*/ opcode on 4+1 ? !S:0::8 2o define fields based on the attributes of another field. 2o define a field as a data area.

$S:0::: What are different ways by which you define worAing storage field ? !S:0::: 3(plicitly define or use 6)iAe D3*/.

$O=0::= &ow many parameters can be defined in a 4+1 program? !O=0::= Ma(. :99.

$)40::4 What are the different ways of ending an 4+1 program without a primary file ? !)40::4 S32O/ )4. S32O/ &8 to &H 7halt indicators;. S32O/ 42. 4324/. 0y allowing an e(ception / error to end the program if . /o e(ception / error subroutine is specified . /o return point is specified on an e(ception or error subroutine

. 2he userKs response is to cancel the program.

$)40::9 Specify different ways by which 4+1 program can gi e error message to user? !)40::9 0y calling the S-04:=4= program as passing message id. 0y defining the error message in DS+*.

$)90::L .f you are trying to add a record in a file and an error is displayed#where do you looA for error ? !)90::L ,hecA whether you ha e opened the file in -pdate mode.,hecA whether you ha e specified K!K in position M: of * specs.

$)90::M What is a *ile .nformation Data Structure ? !)90::M *ile .nformation Data structure 7./*DS; can be defined for each file tomaAe file e(ception/error information a ailable to the program. ! file information data structure contains predefined subfields that identifyB . 2he name of the file for which the e(ception/error occurred . 2he record being processed when the e(ception/error occurred or the record that caused the e(ception/error . 2he last operation being processed when the e(ception/error occurred . 2he status code . 2he 4+1 routine in which the e(ception/error occurred.

$)90::G What is +rogram Status Data Structure ? !)90::G ! program status DS can defined to maAe program e(ception/error information a ailable to an 4+1 program.DS is defined as a program status DS by an S in position 8G of the DS statement. 6S2!2-S contains status code 64O-2./3 contains name of routine in which the e(ception/error occurred.

6+!4MS contains the number parameters passed to this program from the calling program. Specify heading information/2.2)3. Specify to begin on a fresh page/3@3,2. 2o control line spacing/S+!,3. 4ecords to be inserted from other files at the point where it is specified/,O+5.

$O=0::HWhat is the ma(imum no. of times multiple occurrence DS can occur in a program ? !O=0::H HHHH.

$)=0:=0 What is the difference between 6).E3 and 6/!M<!4 ? !)=0:=0 6).E3 defines the ariables as in database. 6/!M<!4 is used to define ariables as data area.

$)=0:=8 &ow is embedded S$) used in 4+1 ? !)=0:=8 /3F3, S$) N S$) statements N """""""""""""""""""" N """""""""""""""""""" /3/D 3F3,

$S=0:=: What are all the compiler directi e statements ? !S=0:=: /2.2)3# /3@3,2# /S+!,3# /,O+5.

$S40:== &ow can 4+1 program send message to System Operator ? !S40:== -se $,MD3F, as called program in the ,!)) statements# and use S/D+1MMS1 to the operator.

$)90:=4 Where D0,S data will be used in 4+1 ? !)90:=4 .n any comment statement . .n comment field of 3 and , Specs . .n literals and constants . !s data in any character field# subfield# array or table.

$S40:=9 Where will control be passed after the e(ecution of the 6+SS4 subroutine if the factor : of the 3/DS4 is blanA ? !S40:=9 ,ontrol will return to the ne(t se>uential instruction.

$S40:=L &ow can the ,+* error"id be retrie ed when a program error occurs ? !S40:=L ,+* error codes are placed in the subfield location 6S2!2-S for the program status DS.

$S=0:=M &ow could indicators 90 to HH be set to K0K in one instruction ? !S=0:=M -sing KMO<3! 6I34OS ./#90K .

$)=0:=G What are the figurati e constants ? !)=0:=G 60)!/E/60)!/ES# 6I34O/6I34OS# 6&.<!)# 6)O<!)# 6!)) KF..K are implied literals that can be supplied without a length# because the implied length and decimal positions of a figurati e constant are 2he same as those of the associated field.

$O=0:=H What is the ma(imum error se erity for which the compilation of 4+1 program stops? !O=0:=H 90# if )4 is not seton.

$LS:008 What are the earlier ersions of 4+1 ? !L!S:0084+1 .. % 4+1 ....

$L)400: /ame the different ways by which 4+1 source program can be entered ? !L)400:.nteracti ely with S3-# .n batch by using either OS/400 or Spooling functions.

$LO=00=During input operation which indicator position is seton if the record is locAed ? !LO=00=+osition 9L " 9M 7)O;.

$LO9004 What is the record locA status alue ? !LO9004Status alue is 08:8G.

M.S,3))!/3O-S

$O=0:40 &ow do you combine two record formats in 4)- ? !O=0:40 -sing ,),.

$O=0:48 &ow do you split record formats in 4)-? !O=0:48 -sing ,)4.

$O:0:4: What is the use of SD!? !O:0:4: Screen Design !id is used to create display files interacti ely.

$O40:4= &ow do you define o erlapping fields in SD! ? !O40:4= 2hey can be defined through condition indicators.

$S40:44 Mention different ways of specifying user help. !S40:44 2hrough SD! and +anel 1roup.

$S=0:49 2o which member type does help te(t for panel belong ? !S=0:49 +/)14+

$O:0:4L ,an +rinter files be e(ternally described or program described ? !O:0:4L 5es.

$S:0:4M What are the alid file operation codes for a +4./234 file ? !S:0:4M W4.23# O+3/# ,)OS3# *3DO.

$S90:4G .f you use ./D!4! Aeyword for a program"described +4./234 file# what will be the result ? !S90:4G 5ou will get run"time error.

$)90:4H What is +42,2)# and where will you define it ? !)90:4H 2he +42,2) 7+rinter ,ontrol; option allows you to change forms control information and to access the current line alue within the program for a program" described +4./234 file. +42,2) option will be specified on a * specifications continuation line for the +4./234 file.

$GS:008 What is the function of 4)- ? !GS:0082o design % prototype a report.

$GS:00: What are the three types of Aeywords associated with printer file?

!GS:00:*ile le el# 4ecord le el % *ield le el.

$GS:00= What are the three line types in 4)- ? !GS:00=4eport line# *iller line % Sample line.

$GO8004 Which option number is used to in oAe 4)- ? !GO8004Option 8H.

$G)4009 What are the different commands used in 4)- ? !G)4009D4 " Define 4ecord# ,), " ,hange )ine for ,ontinuation# ,)4 " ,hange )ine for 4ecord# SD " ,reate Sample Data# <* " <iew *ields# /+ " /ew +age# D, " Define ,onstants# D* " Define *ields# ,* " ,entre *ields % S+ " Space *ields e enly.

$GO800L What is the command used to in oAe 4)- ? !GO800L S244)-.

$GS800M What are different record spacing Aeywords in 4)- ? !GS800M SE.+!# SE.+0# S+!,3! % S+!,30.

$G)400G What is 'ob description ? !G)400G! 'ob is an unit of worA on the !S/400. @obs run in a subsystem using system resources i?. memory# disA# etc. ! 'ob can be either interacti e or batch. *or interacti e 'obs @OD in -ser profile is used and for batch 'obs @O0D along with

S0M@O0 is submitted with an ob'ect type of 'ob description is 6@O0D. @ob

description is a set of characteristics that define how the system handles a 'ob. .t containsB @ob >ueue 7only for batch;# 'ob priority# printer to be used# O-2$ % its priority# time slice % run priority. .f none of the abo e is specified the system used the default 'ob description.

$G)400H Define a sub system? !G)400HSub system is an operating en ironment# defined by a sub system description. !ll user 'obs are processed in the sub system. 3g.$0!S3# $0!2,&# $,2)# $./234# etc. Sub system description defines the characteristics of a sub system. 4O-2./1 3/245B Specifies the program to be called to control a routing step. WO4E 3/245B Source from which 'obs can be accepted. WO4E S2!2.O/ 3/245B Display stations from which users can log into the sub system.

$G)4080 Open >uery file OO+/$45*P? !G)4080Open >uery file 7O+/$45*; selection can be onB 6 Dynamic record selection 6 Dynamic Aeyed se>uence 6 Dynamic 'oin 6 -ni>ue Aey processing 6 1roup processing 6 *inal total processing 6 .mpro e performance $uery access path will be implemented through the following ob'ects 6 ,) program containing an O+/$45* to open access path at runtime 6 OS/400 physical file used to compile programs Odummy +*P used at runtime

6 OS/400 logical file defines the Aey to O+/$45* command

$G)4088 O erride database OO<4D0*P ? !G)4088O erride database OO<4D0*P lets to o erride the filenames or attributes of file selected when we compile/run program. O errides can be used to change most of the attributes. 2o cancel the o erride database command we shall ha e to gi e delete o erride databases D)2O<4.

$G)4088 &ow do you pass numeric parameters for submit 'ob? !G)4088,on ert numeric parameters to character and pass# or.pass in he(adecimal format7(C0nfC if QnC contains odd number of digits (CnfC if QnC contains e en number of digits;

You might also like