Help required in HEX ON command

Ask/Clarify the questions on TSO, CLIST & REXX

Moderators: Veera, Moderator Group

Post Reply
chan3183
Member
Posts: 9
Joined: Sat Apr 18, 2009 8:46 pm

Help required in HEX ON command

Post by chan3183 » Wed May 06, 2009 9:50 am

Hi all,

I received dataset which have 1000 records. When I use 'hex on' to read the record on TSO, it displays like this.

Line 1:

3057HB
444444444313FFFFCC
00000000030C305782

Line 2:

5057HB
444444444315FFFFCC
00000000040C505782


At column 10,11 and 13 can be any digits or alphabets. What is the command to filter only those lines.
As you all know x'40' for space.

Note: Dataset format is PS(Sequential dataset)
Thank you,
Chandru

Anuj Dhawan
Moderator
Posts: 1625
Joined: Sat Aug 09, 2008 9:02 am
Location: Mumbai, India

Post by Anuj Dhawan » Wed May 06, 2009 12:37 pm

Hi,

I doubt your data is "same as posted". Probably line one is like:

Code: Select all

            3057HB 
444444444313FFFFCC 
00000000030C305782 
and line 2:

Code: Select all

            5057HB 
444444444315FFFFCC 
00000000040C505782 
if yes, please BBcode when posting some code to keep the indentation of text correct.

And when I use the above "corrected data" in one of Mainframes file it shows like this:

Code: Select all

----+----1----+----2-
*********************
           3057HB    
444444444313FFFFCC   
00000000030C305782   
If this is the the correct data, what output do you want from this input?
Last edited by Anuj Dhawan on Thu May 07, 2009 8:51 pm, edited 1 time in total.
Regards,
Anuj

Anuj Dhawan
Moderator
Posts: 1625
Joined: Sat Aug 09, 2008 9:02 am
Location: Mumbai, India

Post by Anuj Dhawan » Wed May 06, 2009 1:44 pm

Hi,

If understood correctly, may be you can try this:

Code: Select all

OPTION COPY                   
OUTREC FIELDS=(10,1,11,1,13,1)
in a sort job.
Regards,
Anuj

chan3183
Member
Posts: 9
Joined: Sat Apr 18, 2009 8:46 pm

Post by chan3183 » Thu May 07, 2009 8:12 pm

Hi Anuj,

sorry for the wrong indentation. The expected value can be in any column. so i can't define the column value..
The problem is i couldn't view the value of that particular fields

line 1:
313
30C

line 2:
315
40C

I hope u understand this problem well. Is there any solution for solving this issue.
Thank you,
Chandru

Anuj Dhawan
Moderator
Posts: 1625
Joined: Sat Aug 09, 2008 9:02 am
Location: Mumbai, India

Post by Anuj Dhawan » Thu May 07, 2009 9:45 pm

In your latest post you say:
chan3183 wrote:The expected value can be in any column. so i can't define the column value..
while in your first post you said:
At column 10,11 and 13 can be any digits or alphabets. What is the command to filter only those lines.
I'm not sure what's your final motive . . . :?

And 'am not sure for what this
The problem is i couldn't view the value of that particular fields

line 1:
313
30C

line 2:
315
40C
is posted? What does this convey?
I hope u understand this problem well. Is there any solution for solving
I thought so but your latest post has confused me.
Regards,
Anuj

chan3183
Member
Posts: 9
Joined: Sat Apr 18, 2009 8:46 pm

Post by chan3183 » Fri May 08, 2009 9:39 pm

Hi Anuj,
Sorry for the confusion. Please leave my previous posts as i forgot to mention the details correctly.

The dataset contains more than 1000 records. When i enter HEX ON it displays like the following..( i just give 2 lines(line 1 and line 10) as an example)
************************************
Line 1:
-------------------3057HB
444444444313FFFFCC
00000000030C305782

Line 10:
------------------5057HB
444444444315FFFFCC
00000000040C505782
***********************************
Where,

3057HB & 5057HB are values and dotted lines represent spaces.

But for line 1:
313
30C

and line 10:
315
40C


I can only see the HEX code and not the corresponding values. The hidden values are in different columns and not all the rows contains the hidden values.
Only few rows contains like this. Rows like 2,3...9 contains correct format( displays HEX code with its corresponding values)
Thank you,
Chandru

Anuj Dhawan
Moderator
Posts: 1625
Joined: Sat Aug 09, 2008 9:02 am
Location: Mumbai, India

Post by Anuj Dhawan » Sat May 09, 2009 4:27 pm

Hi Chandru,

Please try using a SORT card similar to this one:

Code: Select all

OPTION COPY                    
OUTREC FIELDS=(10,1,11,1,13,1)
in above 10, 11 and 13 are the positions of the vairable which you want to extract in output . . . you might need to chang them as per your needs.
Regards,
Anuj

chan3183
Member
Posts: 9
Joined: Sat Apr 18, 2009 8:46 pm

Post by chan3183 » Tue May 12, 2009 9:05 am

Hi,

Thanks a lot for ur time being help
Thank you,
Chandru

Anuj Dhawan
Moderator
Posts: 1625
Joined: Sat Aug 09, 2008 9:02 am
Location: Mumbai, India

Post by Anuj Dhawan » Tue May 12, 2009 10:41 am

You're welcome -- but did you get the desired results?
Regards,
Anuj

chan3183
Member
Posts: 9
Joined: Sat Apr 18, 2009 8:46 pm

Post by chan3183 » Tue May 12, 2009 4:03 pm

Hi Anuj,

Sorry for the inconvenience. As i am in vacation i cant check the output anyway i will check the o/p on next week and let u all know the result
Thank you,
Chandru

Anuj Dhawan
Moderator
Posts: 1625
Joined: Sat Aug 09, 2008 9:02 am
Location: Mumbai, India

Post by Anuj Dhawan » Tue May 12, 2009 8:42 pm

Sure,

have a good one,
Regards,
Anuj

Post Reply

FREE TUTORIALS

Tutorials
Free tutorials from mainframegurukul
  • JCL Tutorial
    Covers all important JCL concepts.
  • Cobol Tutorial
    This tutorials covers all Cobol Topics from STRING to COMP-3.
  • DB2 Tutorial
    DB2 Tutorial focuses on DB2 COBOL Programming.
  • SORT Tutorial
    This Tutorial covers all important aspects of DFSORT with examples
  • CICS Tutorial
    This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Interview
Mainframe Interview questions



Other References
Mainframe Tools and others