Given the following code segment:
d ByType s n
d ByProcess s n
d ByData s n Inz
d Result s n Inz
d Work1 s 8
/FREE
ByType = %Len(Work1) > 5;
ByProcess = ByType;
Result = (ByProcess and ByData) or (ByData and ByType)
or (ByType and ByProcess);
/END-FREE
What is the value of field Result after the code is run?
A. *blank
B. *zero
C. *on
D. *off
正解:C
質問 2:
What RPG construct allows the compiler to validate the size and type of the parameters passed on a program call?
A. The %PARMS built-in function
B. A Prototype
C. A Procedure Interface
D. An *ENTRY PLIST
正解:B
質問 3:
File CustSales contains a record format CustSalesR, which includes twelve sales buckets named SaBuck01 through SaBuck12. Given the following code segment:
fCustSales if e k disk
d SalesHist e ds extname(CustSales)
d SalesArray s dim(12) like(SaBuck01) based(Sptr)
d Sptr s * inz(%addr(SaBuck01))
What is the purpose of data structure SalesHist?
A. To prevent level checks in the event of changes to record format CustSalesR
B. To ensure that the sales buckets are contiguous in memory
C. To allow the field names to be qualified with the file name
D. To ensure that the sales buckets are in packed decimal format
正解:B
質問 4:
File CustFile contains a record format CustR, with a single key field CustNumber. Given the following code segment:
FFilename++IPEASF.....L.....A.Device+.Keywords+++++++++++++++++++++++++ FCustFile if e k disk DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords++++++++++++++++++++++++
+
D Cust# S 5 0
In /Free format, which of the following CHAIN operations will retrieve the customer record for the Customer number in field Cust#?
A. Cust# Chain CustR;
B. Chain Cust# CustFile;
C. Cust# Chain CustFile;
D. Chain CustFile Cust#;
正解:B
質問 5:
In An RPG program with embedded SQL, which of the following indicates that a FETCH statement was attempted, but the cursor was positioned after the last row of the result set?
A. SQLEOF = *On
B. SQLERR
C. SQLCOD = 100
D. SQLCOD < 0
正解:C
質問 6:
When reading through a file using the READP(E) operation, which of the following logical conditions indicates the beginning of the file has been reached?
A. %BOF
B. %EOF
C. %Error
D. %Found
正解:B
質問 7:
An RPG source (PGMA) contains two subprocedures and no H-specs. It is company policy that such ILE programs should NEVER be allowed to run in the Default Activation Group.
Which of the following commands should be used to create the program?
A. CRTBNDRPG PGM(PGMA).....DFTACTGRP(*YES) ACTGRP(QILE)
B. CRTBNDRPG PGM(PGMA).....DFTACTGRP(*YES)
C. CRTBNDRPG PGM(PGMA).....DFTACTGRP(*NO) ACTGRP(*CALLER)
D. CRTBNDRPG PGM(PGMA).....DFTACTGRP(*NO) ACTGRP(QILE)
正解:D
山咲** -
とても読みやすく、
イラストで解りやすく解説しています。わかりやすく書いてあるこのテキストは丁度よい000-268問題集といえます。