How to read files written with COBOL

John Roth newsgroups at jhrothjr.com
Mon May 10 16:07:29 EDT 2004


"Batista, Facundo" <FBatista at uniFON.com.ar> wrote in message
news:mailman.404.1084210463.25742.python-list at python.org...
> People:
>
> I'm trying to convert my father from using COBOL to Python, :)
>
> One difficult thing we stuck into is how to read, from python, files
written
> with COBOL.
>
> Do you know a module that allows me to do that?
>
> It should avoid us the work to write a COBOL program that open the COBOL
> file and write a CSV one (easily readable from python).

What's the OS for the two languages? COBOL from mainframe
to X86ish is very different from some flavor of Windows or Unix
COBOL.

Also, are we talking fixed or variable length records? And if
variable, how are they structured?

In either case, I think the struct module (under String Services)
is what you're looking for.

John Roth
>
> Thank you all!
>
> Facundo Batista
> Desarrollo de Red
> fbatista at unifon.com.ar
> (54 11) 5130-4643
> Cel: 15 5132 0132
>
>
>





More information about the Python-list mailing list