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

sort help: how to replace '#' with SPACES


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

New User


Joined: 26 Sep 2006
Posts: 4

PostPosted: Mon Jan 28, 2008 3:31 pm
Reply with quote

Hi,

how to replace '#' with SPACES in file with hepl of dfsort.

Regards,
Back to top
View user's profile Send private message
krisprems

Active Member


Joined: 27 Nov 2006
Posts: 649
Location: India

PostPosted: Mon Jan 28, 2008 6:05 pm
Reply with quote

What is the position of the field?
What are the attributes of the file?
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Mon Jan 28, 2008 8:41 pm
Reply with quote

Hi all,

I have similar kind of problem . I need to replace all '#' with space for VB file.

Record length is 1200
I am using following sort card

Code:
OPTION COPY                       
ALTSEQ CODE=(7B40) 
OUTREC FIELDS=(1,4,5,1196,TRAN=ALTSEQ),VLFILL=X'40'   


Now the problem is output of this job is going as input of another job & since in this sort card we are filling all the shorter record with spaces so RDW of all the record will show it as 1200 BYTE.
One way which i m thinking is to convert this file into FB at the time of changing all # to spaces & VLFILl with some special character & then again convert it to VB again & use VLTRIM option

Please guide me if we have any other better approch to acheive this.
Back to top
View user's profile Send private message
Skolusu

Senior Member


Joined: 07 Dec 2007
Posts: 2205
Location: San Jose

PostPosted: Mon Jan 28, 2008 9:40 pm
Reply with quote

You don't need to convert the file to FB. You just need to use the correct syntax for VB. p,TRAN=ALTSEQ will do the change from position p to the end of each input record. So the control statements would be:

Code:

//SYSIN    DD *                     
  OPTION COPY                     
  ALTSEQ CODE=(7B40)               
  OUTREC BUILD=(1,4,5,TRAN=ALTSEQ)
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Mon Jan 28, 2008 10:22 pm
Reply with quote

Hi Kolusu,

Thanks for ur input.
I will try it tomorrow & let u know
Back to top
View user's profile Send private message
guptae

Moderator


Joined: 14 Oct 2005
Posts: 1208
Location: Bangalore,India

PostPosted: Tue Jan 29, 2008 11:32 am
Reply with quote

Hi Kolusu,

I have used VLFILL=X'40' OPTION because it showing

Quote:
ICE218A 3 128 BYTE VARIABLE RECORD IS SHORTER THAN 1200 BYTE MINIMUM FOR *OUTREC
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: Tue Jan 29, 2008 9:49 pm
Reply with quote

Quote:
ICE218A 3 128 BYTE VARIABLE RECORD IS SHORTER THAN 1200 BYTE MINIMUM FOR *OUTREC


You could NOT have gotten that error message with the control statements shown in Kolusu's post:

Code:

//SYSIN    DD *                     
  OPTION COPY                     
  ALTSEQ CODE=(7B40)               
  OUTREC BUILD=(1,4,5,TRAN=ALTSEQ)


What control statements are you actually using?
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 Need to set RC4 through JCL SORT DFSORT/ICETOOL 5
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
No new posts JCL sort card - get first day and las... JCL & VSAM 9
Search our Forums:

Back to Top