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
 

 

Find the actual value of a field which is S9(06)V99 COMP-3

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

New User


Joined: 10 Jul 2008
Posts: 14
Location: Chennai

PostPosted: Thu Aug 07, 2008 9:06 pm    Post subject: Find the actual value of a field which is S9(06)V99 COMP-3
Reply with quote

I've a field in my output file . The type of the field is S9(06)V99 COMP-3
and it's in un-readable format in the output file. Could you please let me know the way to find the actual numeric value of that FIELD?
Back to top
View user's profile Send private message

rag swain

New User


Joined: 17 Dec 2007
Posts: 33
Location: pune,INDIA

PostPosted: Thu Aug 07, 2008 9:35 pm    Post subject: Reply to: Find the actual value of a field which is S9(06)V9
Reply with quote

If you have a copybook to map with, you can see the value in Nsync/FileAid. Otherwise if you want it to be in display format you can code in your program
Code:


02 WS-FLD1 PIC S9(06)V99 COMP-3.

02 WS-FLD2 S9(06)V99.

IF WS-FLD1 IS NUMERIC
    MOVE WS-FLD1 TO WS-FLD2
ELSE
    call abend routine/do your stuff to keep the record away from processing
END-IF

Back to top
View user's profile Send private message
rpuhlman

New User


Joined: 11 Jun 2007
Posts: 80
Location: Columbus, Ohio

PostPosted: Thu Aug 07, 2008 9:54 pm    Post subject:
Reply with quote

Hi Ezhil,

If you just want to look, go to option 3.4 in TSO/ISPF, type in your dataset name and press enter. Place a 'b' beside the dataset and press enter. At the command line, type in 'hex'. Locate the starting position of your COMP-3 field ...

Ex:
Code:
 -----------------
E1005001    .....
CFFFFFFF4444000004
5100500100000000C0
 -----------------


In this case, the starting position is 13 and ending is 17. If you still have trouble, holler back.

Rick
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 SORT VSAM file with each field one by... maxsubrat DFSORT/ICETOOL 6 Tue Mar 14, 2017 1:07 pm
No new posts IMS DB-How to update a record (a sing... Nic Clouston IMS DB/DC 9 Thu Mar 09, 2017 4:38 pm
No new posts outrec field outside range Danielle.Filteau SYNCSORT 10 Sat Mar 04, 2017 2:37 am
No new posts 2 byte YEAR from Y'DATE2' field tecnokrat DFSORT/ICETOOL 2 Tue Feb 07, 2017 12:05 pm
No new posts Sort two file having same field, one ... himanshu malik DFSORT/ICETOOL 7 Thu Feb 02, 2017 10:09 am


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