View previous topic :: View next topic
|
Author |
Message |
kumar_jalluri
New User
Joined: 02 Jun 2005 Posts: 24 Location: PUNE
|
|
|
|
Hi,
Is there a way to compare particular columns in a file.
Example:
I want to compare
5 to 30 positions in file1 with 8 to 33 of file2 a nd
35 to 69 postions in file1 with 35 to 69 of file2.
Please give your suggestions... |
|
Back to top |
|
|
guptae
Moderator
Joined: 14 Oct 2005 Posts: 1208 Location: Bangalore,India
|
|
|
|
Hi Kumar,
Your requirement is nt clear. What you want to do after comparing columns from different files? What is recformat & length of input file?what sort product available at your site?Please provide same input and output as well. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Because the solution for sort related questions may vary from product to product, please ensure that you state clearly which sort product you are using.
If you are not sure, then by running a simple sort step shown below, you will be able to find out for yourself.
If the messages start with ICE then your product is DFSORT and the topic will be moved to the DFSORT forum by one of the moderators. Please also post the output of the complete line which has a message code ICE201I, as this will enable our DFSORT experts to determine which release of DFSORT that you have installed. This may also affect the solution offered.
If the messages start with WER or SYT then the product is SYNCSORT and the topic will remain in the JCL forum. Please also post the information telling which version of SYNCSORT is installed, as this may also affect the solution offered.
Thank you for taking your time to ensure that the valuable time of others is not wasted by offering inappropriate solutions which are not relevant due to the sort product being used and/or the release that is installed in your site.
Code: |
//SORTSTEP EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD *
ABC
//SORTOUT DD SYSOUT=*
//SYSIN DD *
SORT FIELDS=COPY |
|
|
Back to top |
|
|
kumar_jalluri
New User
Joined: 02 Jun 2005 Posts: 24 Location: PUNE
|
|
|
|
Hi
All I want to do is... I made some code changes.. The expected result is
The fields 5 to 30 positions in file1 with 8 to 33 of file2 should be same.
similarly 35 to 69 postions in file1 with 35 to 69 of file2. should be same. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
You just repeated the info given in the starting question!
in order to get help You need to answer the questions You are asked ! |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Yes, and Gupta has asked some questions which makes him think that a reasonably easy solution using your sort product maybe available.
I asked the questions to make sure that everyone who reads this thread will see the information that you have provided and if they have a possible solution to know which facilities of the sort product are applicable because we know the sort product and release level.
We do not ask questions for the sake of getting you to go away and do something, but merely to acquire enough information, which you did not supply in your original post, to be able to help you.
So, if you want our help - please answer the questions that have been asked. |
|
Back to top |
|
|
Ronald Burr
Active User
Joined: 22 Oct 2009 Posts: 293 Location: U.S.A.
|
|
|
|
SUPERCE ( ISPF Option 3.13 ) will do what has been requested, if a SORT solution is not required.
See The Manual |
|
Back to top |
|
|
Phrzby Phil
Senior Member
Joined: 31 Oct 2006 Posts: 1042 Location: Richmond, Virginia
|
|
|
|
I was wondering if someone was going to suggest 3,13.
If you haven't used 3.13 before, note that it has a batch mode, which generates JCL you can save for later use.
It also has the parms for specifiying columns.
I suggest testing on small files first if your actual files are big. |
|
Back to top |
|
|
Alissa Margulies
SYNCSORT Support
Joined: 25 Jul 2007 Posts: 496 Location: USA
|
|
|
|
Helo Kumar.
SyncSort's JOIN facility can do what you have asked, but you need to specify what you want in the output. Do you want matched records, unmatched records from File1, unmatched records from File2? Please give more details regarding your desired output and we would be happy to further assist you. (Showing sample input and output records is helpful).
Regards, |
|
Back to top |
|
|
|