IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Attributes to copy from flat file to VSAM file


IBM Mainframe Forums -> DFSORT/ICETOOL
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
suresh_u

New User


Joined: 31 Jan 2004
Posts: 8

PostPosted: Wed Feb 04, 2004 10:14 am
Reply with quote

Hi Friends,
I have one flat file of 70 bytes size.I want to copy all the records to VSAM file(KSDS) for which I have allocated with size of 70 bytes with key size of 5 bytes.
But when I tried to copy ,I am getting error as Inconsistent Data attributes and unable to copy all the records.

Could anyone please help me the size allocation in VSAM file so that all the records from flat file are copied correctly.


Thanks
Suresh. icon_sad.gif
Back to top
View user's profile Send private message
sandip_datta

Active User


Joined: 02 Dec 2003
Posts: 150
Location: Tokyo, Japan

PostPosted: Wed Feb 04, 2004 11:17 am
Reply with quote

Hi Suresh,

Can you please post the code and some other informations like data format etc?

Regards,
Sandip.
Back to top
View user's profile Send private message
suresh_u

New User


Joined: 31 Jan 2004
Posts: 8

PostPosted: Wed Feb 04, 2004 11:43 am
Reply with quote

Hi sandip,

For PS input file , data format = FB,Record length =70
and for Output VSAM (KSDS FILE) data format = FB,RECORD SIZE =70,
KEYLENGTH=5.
Hope this information is enough.


Regards,
suresh.
Back to top
View user's profile Send private message
sandip_datta

Active User


Joined: 02 Dec 2003
Posts: 150
Location: Tokyo, Japan

PostPosted: Wed Feb 04, 2004 12:56 pm
Reply with quote

Hi,

I have done it without any problem. Please elaborate your example with the structure of your base cluster and which tool are you using in JCL. I also don't know your Key position.

I have used following code. Assume VSAM is FB and key is from position 0.
Code:
//JP00395S JOB 1000,'SANDIP',CLASS=B,MSGCLASS=X,MSGLEVEL=(1,1),
//        NOTIFY=SYSUID
//PROCLIB JCLLIB  ORDER=RJPIBF.NDVRND.COSMOS.SRCPROC
//SETHLQ  INCLUDE MEMBER=JPHLQ
//SETLIB  INCLUDE MEMBER=JPLIBCS
//*==============================================================
//DELETE EXEC  PGM=IDCAMS
//SYSPRINT DD  SYSOUT=*
//SYSIN    DD  *
   DELETE-
   OUT.VSAM -
   PURGE-
   CLUSTER
    SET    MAXCC=0
   DEFINE CLUSTER-
   (-
   NAME (OUT.VSAM) -
   SPEED-
   NOERASE-
   INDEXED-
   FREESPACE (10 10)-
   SHAREOPTIONS (3)-
   UNIQUE -
   )-
   DATA-
   (-
   NAME (OUT.VSAM.DATA)-
   CYLINDER (1 1)  -
   RECORDSIZE (70,70)-
   CONTROLINTERVALSIZE (8192)-
   KEYS (5,0)-
   )-
   INDEX-
   (-
   NAME (OUT.VSAM.INDEX)-
   TRACK    (3 1)  -
   CONTROLINTERVALSIZE (4096))
/*
//STEP01   EXEC PGM=IDCAMS
//SYSPRINT DD   SYSOUT=*
//SYSOUT   DD   SYSOUT=*
//IN       DD   *
----+----1----+----2----+----3----+----4----+----5----+----6----+----7
11111abcdefghijklmn                                                   
22222ugfjkgigfuipgipfgpigipwgfui[igipgfipgpiguipgfpigfipgfpgpiyoyoyoyy
33333bvbb.mbv.mbvm.bvm.bvmbbbbhkbnv,n                         gbiiigii
44444yuoqytoqytotyioqytioqtyoqtyoqytoqytoytoiytoytoy                 
5555576095705705790175017097509707609376                      !@#$%?&*
66666bvuipcn[qioyv[ytbvy[qyb 'y o[yo'[yoyyto[b yo                             
/*
//OUT      DD   DSN=OUT.VSAM,DISP=SHR
//SYSIN   DD   *
  REPRO INFILE(IN) OUTFILE(OUT)
/*


Regards,
Sandip.
Back to top
View user's profile Send private message
suresh_unni

New User


Joined: 21 Jan 2004
Posts: 1
Location: Pune

PostPosted: Wed Feb 04, 2004 2:45 pm
Reply with quote

Hi Sandip,
Thanks for your help.Now it is working fine.


Regards,
Suresh icon_smile.gif
Back to top
View user's profile Send private message
sandip_datta

Active User


Joined: 02 Dec 2003
Posts: 150
Location: Tokyo, Japan

PostPosted: Wed Feb 04, 2004 9:01 pm
Reply with quote

What was the problem?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> DFSORT/ICETOOL

 


Similar Topics
Topic Forum Replies
No new posts VSAM LISTCAT INFORMATION JCL & VSAM 2
No new posts Format Binary file to EBCDIC JCL & VSAM 4
No new posts Binary File format getting change whi... All Other Mainframe Topics 7
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
Search our Forums:

Back to Top