Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Removing junk characters from a dataset.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
kalais

New User


Joined: 18 Apr 2006
Posts: 22

PostPosted: Fri Aug 24, 2007 3:53 pm    Post subject: Removing junk characters from a dataset.
Reply with quote

Hi,

I need to remove the junk characters from a dataset which opens in browse mode only. I could not do it in REXX using ISREDIT as it is not opening in EDIT mode.
The command we are using in MACRO is
"CHANGE P'.' ' ' ALL"

Is there any way in COBOL for doing this?


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

shreevamsi

Active User


Joined: 23 Feb 2006
Posts: 305
Location: Hyderabad,India

PostPosted: Fri Aug 24, 2007 3:59 pm    Post subject: Reply to: Removing junk characters from a dataset.
Reply with quote

You need to initiliaze before writing to output file.
Back to top
View user's profile Send private message
kalais

New User


Joined: 18 Apr 2006
Posts: 22

PostPosted: Fri Aug 24, 2007 4:06 pm    Post subject:
Reply with quote

Ya I tried it. It doesnt work as the input file itself contains the junk values.

Thanks,
Kalai
Back to top
View user's profile Send private message
shreevamsi

Active User


Joined: 23 Feb 2006
Posts: 305
Location: Hyderabad,India

PostPosted: Fri Aug 24, 2007 4:11 pm    Post subject: Reply to: Removing junk characters from a dataset.
Reply with quote

OK,

Check out the offset where ur getting the Junt value. U can more spaces in those offset. For this u don't need to write a cobol pgm but a simple sort will do.

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

Global Moderator


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

PostPosted: Fri Aug 24, 2007 4:37 pm    Post subject:
Reply with quote

what exactly is the situation? What is the source of this dataset? Why is it that you want to remove the non-display (P'.') char? How large is the dataset, what is the lrecl?

depending upon what,where,how and why there are many things that can be done. But, if you open a dataset in browse, witiswyg (what is there is what you get).

Can you open in VIEW mode, then an edit macro (or a simple chgall) can replace the non-display char. The nice thing about VIEW is that you can not accidently SAVE; you can only REPLACE, which would require intention.

you could also process the dataset with a REXX Script (invoke the rexx script which would massage the dataset, outputing to a temp ds which the rexx could invoke a browse).
Back to top
View user's profile Send private message
kalais

New User


Joined: 18 Apr 2006
Posts: 22

PostPosted: Fri Aug 24, 2007 5:35 pm    Post subject:
Reply with quote

The dataset contains junk values at random positions. So I can not use SORT to remove it. Also I could not able to open in VIEW mode.

I need to load a table using this dataset , So I need to remove unwanted chatacters.


Sample data in Browse mode, Where the dots gets displayed in the place of a junk value.

MOVE '.........00001 ' TO DFHEIV0
[b]<some data>

MOVE '..}............00001 ' TO DFHEIV0[/b]


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

Global Moderator


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

PostPosted: Fri Aug 24, 2007 5:47 pm    Post subject:
Reply with quote

that looks like post compiled CICS API's. Why are you moving a compiler listing to a table? What are you doing?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Removing Duplicates based on certain ... chandracdac DFSORT/ICETOOL 8 Fri Dec 09, 2016 4:40 am
No new posts FTP - JCL failed while passing FTP co... Suneetha1612 JCL & VSAM 12 Wed Nov 16, 2016 7:33 pm
No new posts To trim spaces in a pipe delimited da... Nish84 COBOL Programming 16 Mon Oct 10, 2016 1:54 pm
No new posts Allocate dataset withour BLKSIZE Susanta CLIST & REXX 2 Thu Sep 22, 2016 11:51 am
No new posts Removing Extra Spaces in a comma sepa... Puspojit DFSORT/ICETOOL 3 Tue Sep 13, 2016 7:46 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us