Function SET183A Use of OPNQRYF XLATE to ignore case
********** COMMENT(=======================================================);
********** COMMENT(Process ........: SET_183);
********** COMMENT(Function .......: SET183A);
********** COMMENT(Created on .....: 13/07/00 at 14:43:32);
********** COMMENT(Description ....: Use of an OPNQRYF Translation table);
********** COMMENT(Version.........: 1);
********** COMMENT();
********** COMMENT(Full Description: The purpose of this function is to);
********** COMMENT(show how the OPNQRYF XLATE function can be used to);
********** COMMENT(ignore case during selection.);
********** COMMENT();
********** COMMENT(Disclaimer: The following material is supplied as an);
********** COMMENT(example only. No warranty is expressed or implied.);
********** COMMENT();
********** COMMENT(=======================================================);
********** COMMENT(Function control options);
FUNCTION OPTIONS(*DIRECT *NOMESSAGES);
********** COMMENT(Define Fields:);
DEFINE FIELD(#S_ADDRESS) TYPE(*CHAR) LENGTH(025) DESC('Get ADDRESS containing');
DEFINE FIELD(#S_QRYSLT) TYPE(*CHAR) LENGTH(256);
********** COMMENT(Define browselist:);
DEF_LIST NAME(#S_LST183) FIELDS((#EMPNO)(#SURNAME)(#ADDRESS1));
BEGIN_LOOP;
REQUEST FIELDS(#S_ADDRESS) IDENTIFY(*DESC) BROWSELIST(#S_LST183);
CLR_LIST NAMED(#S_LST183);
USE BUILTIN(TCONCAT) WITH_ARGS('%XLATE(ADDRESS1 QSYSTRNTBL) *CT "' #S_ADDRESS '"') TO_GET(#S_QRYSLT);
OPEN FILE(PSLMST) USE_OPTION(UOQ) QRYSLT(#S_QRYSLT);
SELECT FIELDS(#S_LST183) FROM_FILE(PSLMST);
ADD_ENTRY TO_LIST(#S_LST183);
ENDSELECT;
END_LOOP;
********** COMMENT(=======================================================);
********** COMMENT(Process ........: SET_183);
********** COMMENT(Function .......: SET183A);
********** COMMENT(Created on .....: 13/07/00 at 14:43:32);
********** COMMENT(Description ....: Use of an OPNQRYF Translation table);
********** COMMENT(Version.........: 1);
********** COMMENT();
********** COMMENT(Full Description: The purpose of this function is to);
********** COMMENT(show how the OPNQRYF XLATE function can be used to);
********** COMMENT(ignore case during selection.);
********** COMMENT();
********** COMMENT(Disclaimer: The following material is supplied as an);
********** COMMENT(example only. No warranty is expressed or implied.);
********** COMMENT();
********** COMMENT(=======================================================);
********** COMMENT(Function control options);
FUNCTION OPTIONS(*DIRECT *NOMESSAGES);
********** COMMENT(Define Fields:);
DEFINE FIELD(#S_ADDRESS) TYPE(*CHAR) LENGTH(025) DESC('Get ADDRESS containing');
DEFINE FIELD(#S_QRYSLT) TYPE(*CHAR) LENGTH(256);
********** COMMENT(Define browselist:);
DEF_LIST NAME(#S_LST183) FIELDS((#EMPNO)(#SURNAME)(#ADDRESS1));
BEGIN_LOOP;
REQUEST FIELDS(#S_ADDRESS) IDENTIFY(*DESC) BROWSELIST(#S_LST183);
CLR_LIST NAMED(#S_LST183);
USE BUILTIN(TCONCAT) WITH_ARGS('%XLATE(ADDRESS1 QSYSTRNTBL) *CT "' #S_ADDRESS '"') TO_GET(#S_QRYSLT);
OPEN FILE(PSLMST) USE_OPTION(UOQ) QRYSLT(#S_QRYSLT);
SELECT FIELDS(#S_LST183) FROM_FILE(PSLMST);
ADD_ENTRY TO_LIST(#S_LST183);
ENDSELECT;
END_LOOP;