/* REXX test of command for 2.3.14 SearchFor */ /* CREATED by D.McRitchie, "The REXX Macros Toolbox", 1991/10/24 */ /* comparable tso rexx exec is search4 */ /* multiple search arguments must be separated by commas */ /* without intervening spaces unless part of search arg. */ /* e.g. ===> @SEARCH4 1a 1b,c2 d2 e2,'3f 3g 3h 3i',j4 */ /* ---------------------------------------------------------- */ /*********************************************************************/ /* Manual for ISPF/PDF Guide and Ref. V3R3 MVS -- SC34-4258-01 */ /*********************************************************************/ /* This macro used to work with the original ISRFSPR panel */ /* but the PGM has probably been changed so that the following*/ /* code now must be added to the ISRFSPR panel under )INIT */ /* Related execs and macros: SRCH400, SRCH401 */ /*********************************************************************/ /* IF (&ZSSFNDSN = &Z) /-* MCRITCHIE 1993/09/20 */ /* IF (&DSSFNDSN ^= &Z) /-* MCRITCHIE 1993/09/20 */ /* &ZSSFNDSN = &DSSFNDSN /-* FOR @SEARCH 1993/09/20**/ /*********************************************************************/ Address "ISREDIT"; "MACRO (TOKEN)" "(DSNX) = DATASET" Parse arg "'"DSN"'" if dsn = '' then dsn = dsnx dsn = ''''||DSN||'(*)''' /* zssfndsn = dsn */ dssfndsn = dsn /* this variable with sept 1993 SYSGEN*/ if token = '' then Address "ISPEXEC" "VPUT (DSSFNDSN)" else do /* conditional update of VPUT arguments */ parse var token zssfs1 ',' zssfs2 ',' zssfs3 ',' zssfs4 ',' , zssfs5 ',' zssfs6 ',' zssfs7 /* single imbedded quotes are invalid, even within double quotes*/ /* -- will not be tested for here, left to SEARCHFOR to tell you*/ do i = 1 to 7 /*interpret executes expression*/ x = "if zssfs"i" /= '' then if substr(zssfs"i",1,1) /= ''''" , " then do;j = index(zssfs"i",' ');if j/=0 then zssfs"i , " = ""'""zssfs"i"""'"";end" /* say x -- to debug*/ interpret x; /*change if any blank, unless begins with quote*/ end if zssfs2 = '' then zssfmult = 'NO'; else zssfmult = 'YES' Address "ISPEXEC" "VPUT (dssfndsn,ZSSFMULT ZSSFS1 ZSSFS2 ", "ZSSFS3 ZSSFS4 ZSSFS5 ZSSFS6 ZSSFS7)" end Address "ISPEXEC" "SELECT PGM(ISRSFM)" /* OPT 2.3.14 Search*/ DSSFNDSN=""; ZSSFNDSN="" Address "ISPEXEC" "VPUT (DSSFNDSN ZSSFNDSN)"