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
 

 

Convert from PD to readable format.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
rguhanath

New User


Joined: 16 Oct 2006
Posts: 80
Location: chennai

PostPosted: Thu Jan 07, 2010 3:33 pm    Post subject: Convert from PD to readable format.
Reply with quote

Hi All,

I have come up with new requirement which is needs to do in Rexx. I have a FB sequential file which has the records with length 68 like below.

Code:

----+----1----+----2----+----3----+----4----+----5----+----6----+---
ABC01   201001000000000000{0000000294000{000000000000{0000000147000{
ABC02123201001000000003209F0000000000000{000000001604H0000000000000{
ABC02776201001000000000054F0000000000000{000000000027C0000000000000{
ABC02467201001000000000078E0000000000000{000000000039B0000000000000{


In above file, we have from

1. 15 to 27 position field was declared as S9(10)V9(3) (not COMP or COMP3)
2. 28 to 41 position field was declared as S9(10)V9(4) (not COMP or COMP3)
3. 42 to 54 position field was declared as S9(10)V9(3) (not COMP or COMP3)
4. 55 to 68 position field was declared as S9(10)V9(4) (not COMP or COMP3)


So, we don't know the exact value in these positions due to it stored in PD or any other format. I want to see exact values for these positions by giving the macro name on command prompt whether the file is open. We need to give the command with parameters in command prompt like...

If it Packed decimal to Decimal ---> Command ===> PDTDC 15,14 (or) PDTDC (15,14)
If it Binary to decimal ---> Command ===> BFTDC 15,14 (or) BFTDC (15,14)

Here PDTDC is the Rexx program name and 15, 14 are parameters which 15 tell the starting of the position and 14 is length of the field. So that from the position it should convert the data to readable format and display it on same position in a file or display the popup temporally (for reference purpose).

We know that we are able to see the exact value by using File-aid. For this we copy the corresponding file layout from the program and store in a member. By using this member we can able to see in File-id. But here I want to eliminate this process like copy the layout and store in a member and open the File-aid...etc. I want just by giving the macro name on command prompt to refer the value at the moment.

Please let me know the process to write this code.


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

superk

Moderator Team Head


Joined: 26 Apr 2004
Posts: 4649
Location: Raleigh, NC, USA

PostPosted: Thu Jan 07, 2010 4:06 pm    Post subject: Reply to: Convert from PD to readable format.
Reply with quote

OK. What have you got, where are you stuck, what specifically can we help with? Offhand, I don't think there's any part of this that hasn't been discussed before and other topics.
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 -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Convert CLIST to REXX cvnlynn CLIST & REXX 12 Tue Jun 27, 2017 2:06 am
No new posts Need to write record of PS File in ex... Chandan1993 JCL & VSAM 1 Wed Jun 07, 2017 1:35 am
No new posts Format record to remove Leading zeroes Learncoholic DFSORT/ICETOOL 14 Wed Apr 05, 2017 2:43 pm
No new posts How to pick only YYMMDD from DATE1P (... atulbaviskar SYNCSORT 7 Wed Mar 22, 2017 11:39 am
No new posts Date and time format in CICS Chandru3183 CICS 2 Sat Mar 18, 2017 12:46 pm


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