Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Hi,

I have 3 files say file A , file B and file C.I want to
form an output file in which i will have all the records
from file A. Files B and C also may contain records that
are present in file A.I want those records also to be
included in my output file.

for eg:

file A contains:
1
2
3

file B contains:
2
4
5

file C contains:
1
3
5

So in my output file should look like:
1
2
3
2
1
3

Can any one help ???.....thanks in advance.







Answer Posted / saikishore

I don't know what are you going to tell in your questions.
I am giving the solution according to your example.
STEP1: JOIN FILEB, FILEC.
//SYSIN DD*
JOIN FILES=F1,FIELDS=(1,1,A)
JOIN FILES=F1,FIELDS=(1,1,A)
JOIN UNPAIRED,F1,F2
REFORMAT FIELDS=(F1:1,1,F2:1,1)
INCLUDE COND=(1,1,CH,EQ,C' ',AND,2,1,CH,EQ,C' ')
SORT FIELDS=COPY
/*
STEP2:
//SORTIN DD DSN=FILEA,DISP=SHR
// DD DSN=OUTPUT FILE OF STEP1,DISP=SHR
//SORTOUT DD DSN=FILE6, <- GIVE ALL THE PARAMETERS
//SYSIN DD *
SORT FIELDS=COPY
/*

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How would you understand error(execution phase)?

1264


how you will the direct the data to spool using sysout option?

2439


How can values be passed from the job stream to an executable program?

1454


How do you create a temporary dataset?

1194


What does a disposition of (MOD,DELETE,DELETE) mean ?

1139


what EXEC statement is and what is the syntax of EXEC statement used in JCL?

1176


Is automatic restart possible in jcl?

1230


Explain about ISPF/TSO Commands

1958


What is Cataloged Procedures?

1174


can any one plzzzzzz tell the jcl code for creating ps using idcams

11676


List the various advantages of using jcl language?

1463


How to submit a jcl from cics?

1158


Many jcl statements contain specific values designed to direct and control the execution of the statement. What are these fields called?

1235


What is multithreading in jcl?

1477


why should SYSIN DD * statement should not be included inside a PROCedure snippet??? please answer this.. i need to know.

2463