I want to acheive two things
1) if the no of delimiter is 28 ,then move in correct file - file1 and if no of delimiter is not 28 ,then move in incorrect file -file2
2) If the 11th field in the correct file is FATCA , and 12th feild in the file is US ,then move in final correct file FILE 3
I have acheived 1)if the no of delimiter is 28 ,then move in correct file - file1 and if no of delimiter is not 28 ,then move in incorrect file -file2
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
Picky hat on (as usual): 1 - you are not wanting JCL but sort control cards (if you do not believe me look up those keywords in the JCL Language Reference manual - not a sort manual)
2 - please note that spacing is retianed when you use the code tags so use them as spaces can be important with control cards
3 - Saying it did not work is useless. Cut and paste the messgaes from your job into the reply box and use the code tags so that everything lines up.
Use the prevew button to check your post before submitting.
What does that mean ? Did you get an error ? wrong result ?
Looking at your code full of mistakes, it must be an error: 'I' missing in INREC, '=' missing in INCLUDE, FNAMES duplicated, INCLUDE conditions out of target...
Include conditions: col 341 contains the first character of parameter %28, col 342 first char of param %29.
No '|' and no FATCA there...
Why no %11 and %12 in the parse statement ?
You have FIXLEN=1 versus C'FATCA'. Do you plan to compress 5 characters into one ?
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
You are also using the same DDName for two OUTFILs. If you want three files, you need three separate FNAMES. If you want two, you need only two OUTFILs.
As Marso indicates, you are doing nothing to actually extract any data except the bars. You need to extract the FATCA-field. You need to include it in your OVERLAY. You need to adjust your start and length for the test of it.
The FATCA data is a subset of the GOOD data. So you need the condition for the GOOD as the first part of your INCLUDE= for the third file, then the FATCA stuff.