|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
COBOL Packed decimal converter to VB decimalDoes anyone know of or know how to convert a COBOL packed decimal in a text
file to a decimal that .NET can work with? we are importing Old COBOL data files that have packed data in them and need to convert it to a form we can use. thanks! Brian,
The first thing you have to know is on what computer the Cobol files are created without conversion. In past there was for every computer almost another format for this. (It is mostly used related to IBM mainframes/midis, however Microsoft and others has as well made a compatible compilers where those things could be used on a PC) Cor Don't know but by Googling I found :
http://jymengant.ifrance.com/jymengant/jurassicfaq.html It should provide a Java class that you could likely port to .NET... -- Show quoteHide quotePatrice "Brian Henry" <nospam@nospam.com> a écrit dans le message de news:uRgAWPgFGHA.1736@TK2MSFTNGP14.phx.gbl... > Does anyone know of or know how to convert a COBOL packed decimal in a text > file to a decimal that .NET can work with? we are importing Old COBOL data > files that have packed data in them and need to convert it to a form we can > use. thanks! > > On Tue, 10 Jan 2006 11:35:13 -0500, Brian Henry wrote:
> Does anyone know of or know how to convert a COBOL packed decimal in a text The other answers to the side, if you have the source of the original COBOL> file to a decimal that .NET can work with? we are importing Old COBOL data > files that have packed data in them and need to convert it to a form we can > use. thanks! program, you'll also need to know the packing used. If memory serves me correctly there were comp-1, -2 and -3. One was actually binary of word length. Packed-2, again if memory serves correctly were the digits split between the high and low order half of an 8 bit word. Thus What was (oh, ebcdic, where art thow?) the 'Number' 78251 (F7 F8 F2 F5 F1) would have been split into pair and packed as 's7 82 51' where s is the sign bit. As a pointer you might want to take a look at http://www.discinterchange.com/TechTalk_COBOL_comp_.html. //al ((I realize this doesn't answer your question, but it might suggest that you need to look more closely at the data - rather than to just suggest 'packed'.)) |
|||||||||||||||||||||||