View previous topic :: View next topic
|
Author |
Message |
murugan_mf
Active User
Joined: 31 Jan 2008 Posts: 148 Location: Chennai, India
|
|
|
|
HI all,
I am creating a VSAM Cluster loading with some sample records.
After that I am creating an alternate index for DEPID and loading records
into it.
But ended up with maxcc=12 and the records in alternate index dataset are not in order.
Code: |
IDC3351I ** VSAM I/O RETURN CODE IS 108 - RPLFDBWD = X'8408006C' |
Please guide me thru the right direction
CopyBook
Code: |
DCL 1 STRUC,
2 EMPID CHAR(4),
2 DATE CHAR(8),
2 DEPID CHAR(5); |
Code: |
xyz.BATCH.CLU
---- +----1----+----2----+----3
*******************************
4045 20091212D1234
4046 20091211D1231
4047 20091111D1234 |
Code: |
xyz.BATCH.CLU.AIX
----+ ----1 ----+----2----+----3
********************************
D1231 4046
D1234 40454047 |
|
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10886 Location: italy
|
|
|
|
look at the manual for the IDC.... message and follow it' s advice |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
Since you didn't provide the base cluster definition, nor the alternate index definition, nor the program statements that tell how the program defines the file, nor the program statements referencing the VSAM file, nor the JCL executing the program referencing the VSAM file ... just exactly what do you expect us to be able to do other than suggest you read the manual for the error messages generated by the system? |
|
Back to top |
|
|
murugan_mf
Active User
Joined: 31 Jan 2008 Posts: 148 Location: Chennai, India
|
|
|
|
Sorry Robert..
Please consider this as my fresh post
Code: |
//STEP20 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//INPUT DD DSN=XYZ.BATCH.INPUT.CLUSTER,DISP=SHR
//SYSIN DD *
DEFINE CLUSTER -
( -
NAME(XYZ.BATCH.CLU) -
VOLUMES(*) -
RECORDSIZE(17,17) -
INDEXED -
KEYS(4,0) -
FREESPACE(10 10) -
RECOVERY -
CYLINDERS(20,10) -
CONTROLINTERVALSIZE(1024) -
FOR(365) -
UNIQUE ) -
DATA (NAME(XYZ.BATCH.CLU.DATA)) -
INDEX(NAME(XYZ.BATCH.CLU.INDEX))
REPRO INFILE(INPUT) -
OUTDATASET(XYZ.BATCH.CLU)
DEFINE ALTERNATEINDEX ( -
NAME(XYZ.BATCH.CLU.AIX) -
RELATE(XYZ.BATCH.CLU) -
NONUNIQUEKEY -
UPGRADE -
VOLUMES(*) -
CYLINDERS(20,10) -
RECORDSIZE(410,410) -
KEYS(5,12) )-
DATA(NAME(XYZ.BATCH.AI.DATA))-
INDEX(NAME(XYZ.BATCH.AI.INDEX))
/*
//STEP12 EXEC PGM=IDCAMS
//INPUT DD DSN=XYZ.BATCH.INPUT.CLUSTER,DISP=SHR
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
BLDINDEX INDATASET(XYZ.BATCH.CLU) -
OUTDATASET(XYZ.BATCH.CLU.AIX)
DEFINE PATH (NAME(XYZ.BATCH.CLU.IX)-
PATHENTRY(XYZ.BATCH.CLU.AIX))
REPRO INFILE(INPUT) -
OUTDATASET(XYZ.BATCH.CLU.AIX)
/* |
Code: |
XYZ.BATCH.CLU.AIX
----+ ----1 ----+----2----+----3
********************************
D1231 4046
D1234 40454047 |
Code: |
XYZ.BATCH.CLUSTE.INPUT
---- +----1----+--
******************
4045 20091212D1234
4046 20091211D1231
4047 20091111D1234 |
Here In my AIX dataset only one record has been processed..
and ended with maxcc=12 .
Here is the error :
Code: |
0
REPRO INFILE(INPUT) -
OUTDATASET(XYZ.BATCH.CLU.AIX)
0IDC3302I ACTION ERROR ON XYZ.BATCH.CLU.AIX
0IDC3314I **RECORD OUT OF SEQUENCE - KEY FOLLOWS:
-000000 F0F0F9F1 F2
0IDC3302I ACTION ERROR ON XYZ.BATCH.CLU.AIX
0IDC3314I **RECORD OUT OF SEQUENCE - KEY FOLLOWS:
-000000 F0F0F9F1 F1
0IDC0005I NUMBER OF RECORDS PROCESSED WAS 1
0IDC0001I FUNCTION COMPLETED, HIGHEST CONDITION CODE WAS 8
0
0IDC0002I IDCAMS PROCESSING COMPLETE. MAXIMUM CONDITION CODE WAS 8 |
|
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8796 Location: Welsh Wales
|
|
|
|
What on earth are you doing
You build the alternate index and then try to REPRO something else over the top of it.
No wonder you have problems. Drop the REPRO and it should be OK. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10886 Location: italy
|
|
|
|
for what reason would You want to repro the base cluster into the AIX....
as per Your jcl |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
Suggestion: you should use the PATH name when accessing an alternate index, NOT the alternate index name.
What do you think you're doing when you do this?
Code: |
REPRO INFILE(INPUT) OUTDATASET(XYZ.BATCH.CLU.AIX) |
You do not ever, as far as I am aware, have to load an alternate index. The alternate index is built upon the base cluster (which is why you must have data records in the base cluster before doing the alternate index define) and VSAM generates and maintains the alternate index records for you. |
|
Back to top |
|
|
murugan_mf
Active User
Joined: 31 Jan 2008 Posts: 148 Location: Chennai, India
|
|
|
|
I thought defining a path will create logical relationship between
base cluster and alternate index..
so I used repro to load the data ..
thank you all for your help. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
Quote: |
I thought defining a path will create logical relationship between
base cluster and alternate index.. |
That's what the RELATE on the alternate index definition does. The BLDINDEX builds the alternate index. The DEFINE PATH allows VSAM to open the alternate index and base cluster for processing as a unit, so changes to the base cluster will be reflected in the alternate index (as long as UPGRADE is specified).
By the way, why is the alternate index RECORDSIZE set to 410,410? The alternate index record size formula is 4 + aix key length + (n times base cluster key length), or 4 + 5 + (100 x 4) = 409, not 410. Furthermore, you're setting the average and maximum to be the same, which surely is not going to be the case. While this is not really wrong in the sense that VSAM will be able to use these values, there's not much logical sense to the values you're using. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
Back to top |
|
|
murugan_mf
Active User
Joined: 31 Jan 2008 Posts: 148 Location: Chennai, India
|
|
|
|
Robert,
Yes you are right it should be 409 instead of 410.
I have given avg amd max record length same as they hold fixed length
records according to my definition of my cluster
Corrrect me if I am wrong. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
Dick I would have said "you can replace your false assumptions with facts". |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
|
|
|
|
Murugan, you do not understand alternate indexes. Read the manual Dick references. Alternate indexes, unless defined with UNIQUEKEY, are never fixed length. |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6248 Location: Mumbai, India
|
|
|
|
IBM has taken that pain long back and provided us with Manuals -- for reference they are linked on the top of this page via the name "IBM Manuals"...! |
|
Back to top |
|
|
murugan_mf
Active User
Joined: 31 Jan 2008 Posts: 148 Location: Chennai, India
|
|
|
|
Oops!! IBM has already taken pain..other wise I may create my own
Anyway thanks Anuj |
|
Back to top |
|
|
Anuj Dhawan
Superior Member
Joined: 22 Apr 2006 Posts: 6248 Location: Mumbai, India
|
|
|
|
Sarcasm deleted by poster. |
|
Back to top |
|
|
|