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

Capturing the EX value x'15' using INSPECT verb


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
ragu.vst

New User


Joined: 07 Nov 2010
Posts: 3
Location: Chennai

PostPosted: Mon Dec 19, 2011 10:12 pm
Reply with quote

Hi all,

My production program is creating a tilde delimitted flat file, which was FTP as DAT file unix scripting. But the problem is, my records are getting broken into 2 lines due to some junk characters in HEX (X'15'). Now i need to capture the variables having the HEX value X'15' using the INSPECT REPLACE verb. Tried various junk characters. not able to identify the X'15'. Please help me how to find that special characer using the INSPECT. I have tried all 32 special characters in the KEYBOARD.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Mon Dec 19, 2011 10:20 pm
Reply with quote

you need to convince your manager that you need keyboard with more than 32 special characters.
Back to top
View user's profile Send private message
Craq Giegerich

Senior Member


Joined: 19 May 2007
Posts: 1512
Location: Virginia, USA

PostPosted: Mon Dec 19, 2011 10:22 pm
Reply with quote

Why not just use X'15' in the inspect replacing statement?
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2501
Location: Atlanta, Georgia, USA

PostPosted: Mon Dec 19, 2011 10:27 pm
Reply with quote

This will convert all X'15' to SPACE -

Code:

            INSPECT WS-DATA-AREA        CONVERTING X'15' TO SPACE.

This is similar to Crag's suggestion.

Mr. Bill
Back to top
View user's profile Send private message
ragu.vst

New User


Joined: 07 Nov 2010
Posts: 3
Location: Chennai

PostPosted: Mon Dec 19, 2011 10:45 pm
Reply with quote

Bill O'Boyle wrote:
This will convert all X'15' to SPACE -

Code:

            INSPECT WS-DATA-AREA        CONVERTING X'15' TO SPACE.

This is similar to Crag's suggestion.

Mr. Bill


tHANKS, will try the same and let you know. Thanks for the help
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Mon Dec 19, 2011 10:58 pm
Reply with quote

Perhaps not so fast. It is your data, don't you feel you'd like to know what the X'15' is before you just ignore it?
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2501
Location: Atlanta, Georgia, USA

PostPosted: Mon Dec 19, 2011 11:01 pm
Reply with quote

Bill W is correct. AFAIK, a X'15' represents an "NL" (New Line) character.

Mr. Bill
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Tue Dec 20, 2011 12:19 am
Reply with quote

Mr Bill's knowledge concurs with my trusty Yellow Card.

Now, if you haven't put the LF into your data, then it exists somewhere from where you are taking the data. Do a proper job, don't just bash it on the way out, investigate it (or raise some paperwork) and get it corrected, if necessary. If you are not expecting LF in your data, you can't just make it disappear if it is present.

Of course, we assume you haven't got any packed or binary fields in your output.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2501
Location: Atlanta, Georgia, USA

PostPosted: Wed Dec 21, 2011 6:43 am
Reply with quote

In the 24X80 (1920-Byte) response-area returned by CICS/CEDA Interface program "DFHEDAP" and CICS/CEMT Interface program "DFHEMTA", you'll find X'15' New Line characters imbedded in the response-area, which allows easy printing of each line.

Mr. Bill
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 -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Capturing Job Execution Information All Other Mainframe Topics 3
No new posts Rexx log capturing CLIST & REXX 15
No new posts Capturing COBOL job and program names... All Other Mainframe Topics 2
No new posts Capturing logs from spool dd JCL & VSAM 6
This topic is locked: you cannot edit posts or make replies. regarding COBOL WRITE verb (VB File H... COBOL Programming 9
Search our Forums:

Back to Top