Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Acu cobol archives
Message
From
29/10/2008 10:21:38
 
 
To
29/10/2008 07:21:19
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Network:
Windows 2008 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01357968
Message ID:
01358069
Views:
20
If these files are not indexed, they are a simple flat ascii file.

Your problem will come from the structure since COBOL loved to use "redefines".

There should be a filename.COB file (IIRC) that will be the file definition file and should look something like

10 Complete Record Name 1 21 ** Gives you the full length of the file
30 Field one fieldtype(length) 1 length+1 ** say length = 9, this would tell you that this field is found in columns 1-10
30 Field two fieldtype(length) 11 length + 1 ** again, assuming a length of 10, field runs from columns 11-21

With a redefines you'd see

10 Complete Record Name 1 250 ** Gives you the full length of the file
30 Field one fieldtype(length) 1 length+1 ** say length = 9, this would tell you that this field is found in columns 1-10
30 Field two fieldtype(length) 11 length + 1 ** again, assuming a length of 10, field runs from columns 11-21
10 Different Record Name redefines Complete Record Name
(layout description here)

When you see a redefines, that will clue you that you need to create a separate table for this data.

But, as long as you have the file structure file, you can create a .dbf from that (either through a script or by hand).

If you have no redefines, you can simply do an "append from filename type sdf" once you've built the structure. If you DO have some redefines, you might have to do an initial table structure, append in the file, and then do some manipulation from there to get it to the final structures.

If you don't have the .COB file (some systems will have a .CBL extension on the definition files), then you need someone who can define the fields for you.



>Hi all , a customer asked me if it was possible to import acu cobol archives into vfp. Of course it is but ...
>how ? anybody knows where to find the odbc drivers ?
>
>thank you
"You don't manage people. You manage things - people you lead" Adm. Grace Hopper
Pflugerville, between a Rock and a Weird Place
Previous
Reply
Map
View

Click here to load this message in the networking platform