View previous topic :: View next topic
|
Author |
Message |
chiraag
New User
Joined: 19 Apr 2005 Posts: 7
|
|
|
|
I need to search for few strings in hundreds of Physical Sequential files. Tedious way is to open up the file and search the string using Find function. this is very time consuming. All the files are variable record lengths and the string that I need to search can occur at any position.
Also I need to search for multiple strings and not just one.
Can someone help ? |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Quote: |
I need to search can occur at any position. |
For searching a value in the record, you can use SS format as in -
Code: |
INCLUDE COND=(1,80,SS,EQ,C'FIRSTCOND',OR,
1,80,SS,EQ,C'SECONDCOND') * lrecl=80 |
Since you also said all a variable file, I believe you need to use one step for one file (huh... tedious proces again for writing the JCL). |
|
Back to top |
|
|
chiraag
New User
Joined: 19 Apr 2005 Posts: 7
|
|
|
|
They are variable blocked records but with same LRECL. Also does the above help to search the entire file or only certain columns? |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Format SS searches in the entire record (i.e., from coulmn 1 to n). So even if you dont know the column value, give the max lrecl in the control card. That should do the trick. |
|
Back to top |
|
|
chiraag
New User
Joined: 19 Apr 2005 Posts: 7
|
|
|
|
This is what I gave:
//SYSIN DD *
INCLUDE COND=(1,26620,SS,EQ,C'RP121PSB')
/*
and it gives me the below error
SYSIN :
INCLUDE COND=(1,26620,SS,EQ,C'RP121PSB')
*
WER251A INCL INVALID LENGTH |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Code: |
//SYSIN DD *
SORT FIELDS=COPY
INCLUDE COND=(1,26620,SS,EQ,C'RP121PSB')
/* |
Use the above sort card. |
|
Back to top |
|
|
chiraag
New User
Joined: 19 Apr 2005 Posts: 7
|
|
|
|
This option gave me the same error. Do I need to convert the VB file to FB file before I can use search string? |
|
Back to top |
|
|
murmohk1
Senior Member
Joined: 29 Jun 2006 Posts: 1436 Location: Bangalore,India
|
|
|
|
Chiraag,
I had used SS on FB file before and not with VB. Could it be possible for you convert the VB file to FB first in step1 followed by search in step2? |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
You are using Syncsort, therefore many of the DFSORT "tricks" will not be available.
Did your process work when you added the
|
|
Back to top |
|
|
|