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

Removing unwanted characters from file.


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

New User


Joined: 06 Aug 2007
Posts: 42
Location: chennai

PostPosted: Fri Dec 28, 2007 1:48 pm
Reply with quote

Is there anf way to way to remove unwanted charcters from file.

EXAMPLE

INPUT

1DW3P.LKP.KBM
'DW4P.LKP.KBM'
#'DW5P.LKP.KBM'
!%#'DW6P.LKP.KBM'
*#'DW7P.LKP.KBM'

OUTPUT

DW3P.LKP.KBM
DW4P.LKP.KBM
DW5P.LKP.KBM
DW6P.LKP.KBM
DW7P.LKP.KBM



ACTUALLY STARTING POSITION IS NOT FIXED FOR THESE ENTERIES :- What i mean to say it not necessary that DW will start from 1 column only and any number of useless symbols can be there before actual name.

Can this be sort out using SORT utility.
Back to top
View user's profile Send private message
scorp_rahul22
Currently Banned

New User


Joined: 06 Aug 2007
Posts: 42
Location: chennai

PostPosted: Fri Dec 28, 2007 1:53 pm
Reply with quote

i try with normal sort utility nut i m not getting that desired result.
how wud i figure out while coding that alphabetic character has come
Back to top
View user's profile Send private message
scorp_rahul22
Currently Banned

New User


Joined: 06 Aug 2007
Posts: 42
Location: chennai

PostPosted: Mon Dec 31, 2007 12:11 pm
Reply with quote

so whats the solution for this ?
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Fri Jan 18, 2008 9:13 pm
Reply with quote

scorp_rahul22 wrote:
so whats the solution for this ?


Have you referred your problem to the SYNCSORT technical support folks? I'm sure they could offer you a solution that will fit your needs.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Developer


Joined: 15 Feb 2005
Posts: 7129
Location: San Jose, CA

PostPosted: Fri Jan 18, 2008 10:01 pm
Reply with quote

If you have DFSORT, you can use the PARSE function to do what you asked for like this:

Code:

//S1    EXEC  PGM=ICEMAN                                       
//SYSOUT    DD  SYSOUT=*                                       
//SORTIN DD *                                                 
1DW3P.LKP.KBM                                                 
'DW4P.LKP.KBM'                                                 
#'DW5P.LKP.KBM'                                               
!%#'DW6P.LKP.KBM'                                             
*#'DW7P.LKP.KBM'     
/*                                         
//SORTOUT DD SYSOUT=*                                         
//SYSIN    DD    *                                             
  OPTION COPY                                                 
  INREC PARSE=(%01=(STARTAT=C'D',FIXLEN=44,ENDBEFR=C'''')),   
   BUILD=(%01)                                                 
/*
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 Compare 2 files and retrive records f... DFSORT/ICETOOL 2
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
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
Search our Forums:

Back to Top