File 1 Having the records in below format
Customer#¦Customer Name¦Project Name¦UserId
7777¦xyz¦Project_7777¦xyza
File 2 Having the records in below format
Customer#¦Customer Name¦Project Name¦UserId
6666¦abc¦Project_6666¦abcd
File 3 Having the records in below format
Customer#¦Customer Name¦Project Name¦UserId
5555¦pqr¦Project_5555¦pqrs
4444¦stu¦Project_4444¦stuv
The output file should have the record in below format(With common Heading):
Customer#¦Customer Name¦Project Name¦UserId
7777¦xyz¦Project_7777¦xyza
6666¦abc¦Project_6666¦abcd
5555¦pqr¦Project_5555¦pqrs
4444¦stu¦Project_4444¦stuv
Also, regarding SUM FIELDS=NONE option. I am afraid if we can use this option as headers might not be identical as there are from .CSV file upload. User may by mistake enter any other characer and hence those header records may not be the duplicates...
Thank once again but i would be grateful if we can use any DFSORT option.
If the position of delimiter '|' of header record and the detail record is fixed and are at different positions in the file then you can use the First discard option.
In the example you have given, the 1 st delimiter for header is at 10th position and 1 st delimiter for detail record is at 5th position. Thus irrespective of what the user has entered you can delete the 2 headers.
Joined: 15 Feb 2005 Posts: 7130 Location: San Jose, CA
mohd,
You really haven't made it clear what you're trying to do and you seem to be contradicting yourself in different posts.
You showed an example with three identical headers, but then you say they may not be identical.
But you also say
Quote:
The output file should have the record in below format(With common Heading):
If the headings were not identical, which heading would you want to use?
If the headings are identical, then why are you saying they might not be identical.
Do you have to use one of the existing headings or can the heading be "rebuilt" to look like this as you showed in your expected output:
Quote:
Customer#¦Customer Name¦Project Name¦UserId
You need to do a better job of explaining exactly what you want and the "rules" for getting from input to output before somebody can help you.
Quote:
I needed DFSORT option instead of ICETOOL.
Why? ICETOOL has been shipped as a fully documented, fully supported part of DFSORT since 1991.
I accept that i did not make myself clear, I am sorry about that.
But presently client doesnt want us to use ICETOOL thats why i am not going for that option.
1. Firstly header will have same values(Here i meant format) in all 3 files, but these 3 files are upload from .CSV files so i expected them to be different (insertion of blank or any other characer in any one of the .CSV files so SUM FIELD =NONE will not work)
So, if there is any other option using which i can i would be grateful to you all. Thanks once again and sorry for the confusion.
Please let me know if the above explanation looks fine.
Joined: 15 Feb 2005 Posts: 7130 Location: San Jose, CA
Well, you didn't answer my question about which of the non-identical headings you wanted in the output file, so I'll assume you want the heading from input file1. Since you can't use ICETOOL and you can't use SUM, you'll need three steps as shown in this DFSORT job. Be sure to use MOD for step2 and step3.
This is perfect...Frank Yaeger ur assumption was right on target to take the first heading(This is what needed)..I ve got 2 options now from you guys without using ICETOOL..Thats wonderful
I thank once again to Ashish Ranjan, mmt_bit, Frank and Skolusu.
I appreciate your cooperation shown in this regard.