Page 1 of 1

query regarding matching field value

Posted: Mon Feb 20, 2006 1:54 pm
by jasveer
hi all
i have a query.
actually i have an input file which has records beginning with a PIC XX field which can hold value 11,14,15, has one more field pic x(15).
now i wanna move all fields from record starting with 11 to a output file.if the picx(15) digit of 11 matches with that of record whose pic xx =21, then i wanna move one field from 21 to corresponding field in output of 11.
let me explain it further.
if one record is 11 123 112123123123123 31 & another record is
21 333 112123123123123 23
record 11 has same pic x(15) as that of 21 so move 31 from 11 and 21 from 21 to same record of output file

Posted: Mon Feb 20, 2006 2:44 pm
by Rupesh.KOthari
HI Jasveer,

COuld you please let us know what exact output do you want :?:



Posted: Mon Feb 20, 2006 3:21 pm
by jasveer
hi rupesh
thanks for the concerns
well we have an input file like
1st 2nd 3rd field 4th
11 123 133333444555555 33
14 321 133234235455555 45
21 321 133333444555555 62

if the 3rd field i.e. pic x(15) of the 11( 1st field ) and 21( 3rd field) are same then move 33( 4th ) from 11 and 62(4th) from 21 to the output file.
the output file should be like( becoz the 3rd fields of 11 and 21 are equal)

1st 2nd 3rd
133333444555555 33 62

reply for rupesh

Posted: Mon Feb 20, 2006 3:51 pm
by jasveer
hi rupesh
Again saying that its some what related to costumers details.

lets say that for same name we have two records
the first having the costumer name,address,
the second one having the name and dob.
if the name for the two records is same then all the fields of the two records should come in single record of the output file .
its like gathering the info of the same costumer from various records thru their identification number and creating an output file thru the same.