I am getting an input in a notepad with 100's of account number which needs to be filtered and ftp'd to my user. I have written a JCL such that it will copy all the records with the particular date range and with the defined account numbers.
Code:
Sample:
SORT FIELDS=COPY
INCLUDE COND=((8,5,PD,GE,20090529,AND,8,5,PD,LE,20090712),AND,
(41,9,CH,EQ,C'123456DH6',OR,
41,9,CH,EQ,C'123456DJ2',OR,
41,9,CH,EQ,C'123456DK9',OR,
41,9,CH,EQ,C'123456DL7',OR,
41,9,CH,EQ,C'123456DM5'))
Here my requirment is everytime i am manually pasting all the Account number into my sort card. Is there any way that we can copy all account# from a file into this sort car?
I can ftp the details from notepad to mainframe with all account number.
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
sounds like what you want to do is have the account no from the notepad as one file, and 'your other file', and only output those from the 'other file' that match your notepad file, as well as filter all from 'the other file' within a given date range.
Adding the '(' for the first account number and the '))' for the last account number would be difficult, so instead we use NOPs for the first and last conditions so we can generate all of the account conditions the same way without worrying about the parens:
The 1,1,BI,NE,1,1,BI conditions will never be true so they act as NOPs. This makes it easier to generate the INCLUDE statement from the list of accounts.
Quote:
Does sort drop duplicate statements ?
No, it doesn't drop duplicate conditions but these two duplicate conditions are NOPs so they don't have any effect on the output records selected.
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
Quote:
I have no idea what is the use of -->1,1,BI,NE,1,1,BI
I explained that in an earlier post - it's a NOP (no operation) that allows us to easily generate the INCLUDE condition from a separate data set with the accounts as requested in your first post. You really don't have to understand it to use the job I provided.
Quote:
The input file is a GDG file. and the requirement here is to change only the sort card account number. Can you please advice me on this.
I thought I did.
In your first post you said:
Quote:
Is there any way that we can copy all account# from a file into this sort card?
That's what I showed you how to do. I don't know what else you are asking for.
Plug the file with the account#s into the SORTIN DD in step S1 (I assumed the account number file is FB and has the account numbers in positions 1-9 - if that's not the case, give me the actual RECFM, LRECL and positions).
Joined: 15 Feb 2005 Posts: 7129 Location: San Jose, CA
We use 80:X to ensure the generated control statements are 80 bytes long (to match the length of the DD * statements). DFSORT control statements are usually 80 bytes long.
I don't know anything about transferring with FB or VB. Maybe somebody else can help.
--- I tried our expert google and searched. Found nothing which matches for my requirement.
Are you asking how to use a VB account number file for the S1 input instead of an FB account number file?
Yes
This could be the alternate method for me if now as i am unable to ftp to FB using macro.