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
 

 

downloading file with comp-3 data

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

New User


Joined: 15 Jan 2008
Posts: 6
Location: India

PostPosted: Tue Apr 07, 2009 11:43 am    Post subject: downloading file with comp-3 data
Reply with quote

Hi,

I have a file which contains comp-3 data, I want to download the file to PC in order to compare it with other file, how can I convert comp-3 data to displayable format, one way I know is, directly in cobol program we can move it to displayable field, but if anybody knows while downloading file what format it should be downloaded so that comp-3 data will be shown as numeric data.
Back to top
View user's profile Send private message

Succor

New User


Joined: 20 Feb 2009
Posts: 96
Location: Bangalore :)

PostPosted: Tue Apr 07, 2009 12:57 pm    Post subject: Reply to: downloading file with comp-3 data
Reply with quote

Pprulz,Its better to use a JCL in comparison to writing a cobol program to achieve what you want. Once the file is converted you can download the same and compare .There several topics available in forum on the same.
Please go through the following link :http://www.ibmmainframes.com/about3353.html

WTF
Back to top
View user's profile Send private message
leo_sangha

New User


Joined: 11 Aug 2005
Posts: 85
Location: England

PostPosted: Tue Apr 07, 2009 3:32 pm    Post subject: Reply to: downloading file with comp-3 data
Reply with quote

you can convert packed decimals to numerics using sort in JCL.
Then you can download. Hope this helps.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 7931
Location: Bellevue, IA

PostPosted: Tue Apr 07, 2009 4:54 pm    Post subject:
Reply with quote

Quote:
but if anybody knows while downloading file what format it should be downloaded so that comp-3 data will be shown as numeric data.
It can't be done -- packed decimal values can be perfectly valid as is, so the conversion must be done before the download.

For example, X'97994D' may be a packed decimal -97994 value. On the other hand, X'97994D' also represents 'pr(' in EBCDIC -- which may be part of a Unix System Services command string. If you convert it during download and it is supposed to be pr( you've just screwed up the command; if you leave it alone but it is a packed decimal value that you're downloading as text (so the EBCDIC to ASCII conversion occurs) you've just changed it to X'70727B'. There's no way to tell how to handle it during the download so it must be taken care of before the download.
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 SORTJOIN - Copy Matched and Unmatched... Steve Ironmonger DFSORT/ICETOOL 4 Tue Jan 17, 2017 4:26 pm
No new posts Storing huge volume of data, compare ... Pradeep K M All Other Mainframe Topics 3 Mon Jan 16, 2017 5:08 pm
No new posts how to recover an uncataloged VSAM da... archanamuthukrishnan All Other Mainframe Topics 3 Wed Jan 11, 2017 6:18 pm
No new posts HALDB data refresh/copy from producti... vineetanand2007 IMS DB/DC 0 Mon Jan 02, 2017 11:16 am
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm


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