jgantena New User Joined: 13 Aug 2008 Posts: 8 Location: Hyderabad
Can someone help me out in resolving the query.
I m trying to copy data from Flat file of variable length to VSAM file of variable length, i me getting issue like VSAM logical error.
1)Initially i copied data from a VSAM file which is a VB length file(123 bytes) to a flat file of length 145 bytes with recfm VB.
For that i added 4 bytes additional to my actual file length like below
//SORTIN DD DSN=DARN1.VSO.DCR1.AMNK1,DISP=SHR
//SORTOUT DD DSN=DARN1.FFB.DCR1.AMNKA.SORT,
while copying i kept condition like SUM FIELDS=NONE to remove duplicates. Then all the recs were copied.
2)Now when i try to copy data from the above flat file to a new VSAM file which is defined with below parameters
RECORDSIZE ( 105 145 )
KEYS ( 40 0 )
getting a VSAM logical error after some records are copied into VSAM file.
When i manually check the input flat file,there were no duplicates also.
Could some help on this.
dbzTHEdinosauer Global Moderator Joined: 20 Oct 2006 Posts: 6970 Location: porcelain throne
1. i have found that, when using sort, i am better off not specifiying lrecel ,
sort does a much better job of calculating the lrecl than I do.
2. had you done the above, you could have used sort to copy the flat file back.
3. have you insured that the new vsam is defined exactly as the originial. (the define parms should have used model).
Frank Yaeger DFSORT Moderator Joined: 15 Feb 2005 Posts: 7130 Location: San Jose, CA
expat Global Moderator Joined: 14 Mar 2007 Posts: 8631 Location: Back in jolly old England
You also need to post all of the error messages AND codes that were issued by the failing job.
All times are GMT + 6 Hours