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

Syncsort deleting records from VSAM file


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Rajeev_mainframe

New User


Joined: 21 Aug 2006
Posts: 13

PostPosted: Tue Dec 08, 2009 2:32 am
Reply with quote

I saw this code delete specific records from VSAM file. I tried doing it and it is actually deleting the records from VSAM but everytime my job is abending with below error message

VSAM LOGICAL ERROR 0C ON OUTPUT
SYNCSMF CALLED BY SYNCSORT; RC=0000
SYNCSORT GLOBAL DSM SUBSYSTEM ACTIVE

The JCL looks like:
Code:

//S1  EXEC PGM=SORT
//SYSOUT DD SYSOUT=*                           
//SORTIN   DD DSN=VSAM.DATASET,DISP=SHR
//SORTOUT  DD DSN=VSAM.DATASET,DISP=SHR
//SYSIN DD *                                   
  OPTION VSAMIO,RESET                         
  OMIT COND=(14,9,CH,EQ,C'544628DQ0')                               
  SORT FIELDS=(3,1,BI,A)                       
  RECORD TYPE=V                               
/* 


since Record type is V I am adding 4 bytes to the position. and for SORT Field this was the explanation given:

Sorting on the 3rd byte of the RDW and using EQUALS - since the third byte of the RDW is always X'00', this will ensure that the records that are not omitted are kept in their original order.


Thanks
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Tue Dec 08, 2009 7:35 am
Reply with quote

why don't you just do a copy / or is your input the same dsn as output?

why is the 3rd byte of the RDW always x'00'?
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Tue Dec 08, 2009 7:55 am
Reply with quote

Quote:
since the third byte of the RDW is always X'00'
One of these days you'll run into VBS (variable, blocked, spanned) record format for files and are you going to be surprised.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Tue Dec 08, 2009 1:39 pm
Reply with quote

"why is the 3rd byte of the RDW always x'00'?"

Frank Yaeger said that here :

www.***READ FORUM RULES***.net/vbforums/showthread.php?t=24762

DFSORT info on vsam :

publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/ICE1CA20/1.8.3.4?SHELF=&DT=20060615185603&CASE=
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Tue Dec 08, 2009 8:08 pm
Reply with quote

thank you Peter.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2481
Location: Netherlands, Amstelveen

PostPosted: Tue Dec 08, 2009 10:20 pm
Reply with quote

dbzTHEdinosauer wrote:
thank you Peter.


Well we are almost neighbours, so we should help each other.
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 4
No new posts Extract the file name from another fi... DFSORT/ICETOOL 6
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
Search our Forums:

Back to Top