From: Howard Brazee on 8 Feb 2006 10:09 On 7 Feb 2006 18:32:01 -0800, "mftips(a)gmail.com" <mftips(a)gmail.com> wrote: >To Search for a particular string within a file when the exact position >of that string within a record is not known and to write that record in >the Output file the following SORT card can be used. > >Example 1: >SORT FIELDS=COPY >INCLUDE COND= (1, 80, SS, EQ, C'FIND STRING') This is not the best forum for a SORT question. If you are referring to IBM's mainframe sort, you might want to e-mail Frank Yeager yaeger(a)ibm-main.lst or join the IBM list server list: ibm-main(a)bama.ua.edu, (which he subscribes to), or look at the newsgroup that has a copy of that listserver (which he may or may not catch) bit.listserv.ibm-main . Or check http://www-03.ibm.com/servers/storage/support/software/sort/mvs/professor_sort/srtmainf.html
From: on 9 Feb 2006 08:41 In article <m12ku1lkrkudaa1bbglofuqu9l357tb63f(a)4ax.com>, Howard Brazee <howard(a)brazee.net> wrote: >On 7 Feb 2006 18:32:01 -0800, "mftips(a)gmail.com" <mftips(a)gmail.com> >wrote: > >>To Search for a particular string within a file when the exact position >>of that string within a record is not known and to write that record in >>the Output file the following SORT card can be used. >> >>Example 1: >>SORT FIELDS=COPY >>INCLUDE COND= (1, 80, SS, EQ, C'FIND STRING') > >This is not the best forum for a SORT question. I did not read this as a question, Mr Brazee, I read it as a suggestion/tip... and it was a new one to me, too. I've used batch SUPERC jobs to do this in the past, eg: //SEARCH EXEC PGM=ISRSUPC, // PARM=(SRCHCMP, // 'ANYC') //NEWDD DD DSN=YOUR.DSN.HERE, // DISP=SHR //OUTDD DD SYSOUT=* //SYSIN DD * SRCHFOR 'SMITH' CMPCOLM 1:200 .... but I was unaware that DFSORT could do this ('SS' as a format is mentioned in the documentation here and there but appears to be missing from <http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA00/3.7.2.1?DT=20031124143823#TBLBOZO> and <http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA00/C.1?SHELF=&DT=20031124143823&CASE=> ... and to learn A New Thing can be pleasant. E'en more interesting... I just ran a test against a VSAM KSDS, LRECL=350, about 65,000 recs, searching for 'SMITH' in columns 1 - 200. ISRSUPC used 1538 I/O counts (whatever those measure) and 2.04 CPU sec, DFSORT (REL 14.0) used 202 I/O counts and 1.10 CPU sec. DD
From: Howard Brazee on 9 Feb 2006 09:16 On Thu, 9 Feb 2006 13:41:21 +0000 (UTC), docdwarf(a)panix.com () wrote: >I did not read this as a question, Mr Brazee, I read it as a >suggestion/tip... and it was a new one to me, too. I've used batch SUPERC >jobs to do this in the past, eg: Here's some compare JCL I've used that you might find interesting. //TBEB EXEC PGM=IEFBR14 //SORTOUT DD DSN=UMS.D44201.TEMP, // DISP=(MOD,DELETE),SPACE=(TRK,0) //SORTSTEP EXEC PGM=SORT //SORTIN DD DSN=,DISP=SHR // DD DSN=UMS.D44201.LAMV.LOAN.MASTER,DISP=SHR //*DFSPARM DD DSN=UMS.TEST.DATA(DYNALLOC),DISP=SHR //*SORTWK01 DD UNIT=SYSDA,SPACE=(CYL,82,,CONTIG) //*SORTWK02 DD UNIT=SYSDA,SPACE=(CYL,82,,CONTIG) //*SORTWK03 DD UNIT=SYSDA,SPACE=(CYL,82,,CONTIG) //SORTOUT DD DSN=UMS.D44201.TEMP, // UNIT=DEVEDISK, // SPACE=(CYL,(75,15),RLSE), // DCB=(RECFM=FB,LRECL=1200,BLKSIZE=12000), // DISP=(NEW,CATLG,DELETE) //SYSOUT DD SYSOUT=* //SYSIN DD * SORT FIELDS=(01,1010,A), FORMAT=CH SUM FIELDS=NONE ELIMINATE DUPLICATES //SUPERC EXEC PGM=ISRSUPC, * // PARM=(DELTAL,LINECMP, // ' NOSEQ', // '') //NEWDD DD DSN=UMS.D44201.LLDJ.MSTRFILE, // DISP=SHR //OLDDD DD DSN=UMS.D44201.LAMV.LOAN.MASTER, // DISP=SHR //OUTDD DD SYSOUT=(*) //SYSIN DD * OFOCUS COLS 1101:1115 NFOCUS COLS 1101:1115 LSTCOLM 1101:1115 /* // CMPCOLM 30:60,75 HTTP://PUBLIBZ.BOULDER.IBM.COM/CGI-BIN/BOOKMGR_OS390/BOOKS/ISPZU220/APPENDIX1
From: on 9 Feb 2006 10:03 In article <2fjmu1ldr7aomn0g69vjb6epqj49qp674h(a)4ax.com>, Howard Brazee <howard(a)brazee.net> wrote: >On Thu, 9 Feb 2006 13:41:21 +0000 (UTC), docdwarf(a)panix.com () wrote: > > >>I did not read this as a question, Mr Brazee, I read it as a >>suggestion/tip... and it was a new one to me, too. I've used batch SUPERC >>jobs to do this in the past, eg: > >Here's some compare JCL I've used that you might find interesting. [snip] >LSTCOLM 1101:1115 *Most* interesting... thanks much! DD
From: yaeger on 9 Feb 2006 12:44 docdwarf(a)panix.com wrote: >... > ... but I was unaware that DFSORT could do this ('SS' as a format is > mentioned in the documentation here and there but appears to be missing > from > <http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA00/3.7.2.1?DT=20031124143823#TBLBOZO> > and > <http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA00/C.1?SHELF=&DT=20031124143823&CASE=> > ... and to learn A New Thing can be pleasant. You're looking too deep into the DFSORT doc. If you started at the beginning of the INCLUDE statement doc, you would have found it: http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA10/3.7?DT=20050222160456 See 2. under the four types of relational conditions. Also, see this item on the DFSORT website: http://www.ibm.com/servers/storage/support/software/sort/mvs/beyond_sorting/online/srtmbinc.html#ssl And if you want to see some even fancier stuff that DFSORT can do, look for IFTHEN, OVERLAY, UFF, SFF, etc in my paper on DFSORT's Dec, 2004 PTF: http://www.ibm.com/servers/storage/support/software/sort/mvs/pdug/index.html Frank Yaeger - DFSORT Team (IBM) - yaeger(a)us.ibm.com Specialties: ICETOOL, IFTHEN, OVERLAY, Symbols, Migration => DFSORT/MVS is on the Web at http://www.ibm.com/storage/dfsort/
|
Next
|
Last
Pages: 1 2 3 Prev: MicroFocus & mainframe sequential files Next: COBOL II to Enterprise COBOL |