Code Comments
Programming Forum and web based access to our favorite programming groups.Is there a way to access the Microfocus Data file? ODBC? OLEDB? Stephen K. Miyasato
Post Follow-up to this messageStephen K. Miyasato wrote: > Is there a way to access the Microfocus Data file? ODBC? OLEDB? > > Stephen K. Miyasato Uh, what's a "Microfocus Data file?"
Post Follow-up to this message
"Stephen K. Miyasato" <miyasat@flex.com> wrote in message
news:45217f03$0$25775$ed962e05@news.felx.com...
> Is there a way to access the Microfocus Data file? ODBC? OLEDB?
>
> Stephen K. Miyasato
>
>
You can access these files with a COBOL program. They are not MicroFocus
files; they are files written by the MicroFocus COBOL file system.
If you are unable to write such a program (no COBOL software) you should use
a utility to try and decipher the format and content of them ('Packrat' has
been well spoken of here...). You can then write something in any of the
popular languages to access them.
If you have the COBOL source code, with the file definition, I have a
component that will access the data. I have another component that will
convert the data structure to an ODBC accessible Relational Data Base (MySQL
or Access - easily exportable to SQL Server or Oracle, if required), and
generate a module to load the DB with the existing data from the file. This
'opens up' the closed COBOL file system, as the RDB can be accessed with
standard software like Access, Excel, etc.
If you don't have the source, you should brace yourself for pain...
Pete.
Post Follow-up to this message> If you have the COBOL source code, with the file definition, I have a
> component that will access the data. I have another component that will
> convert the data structure to an ODBC accessible Relational Data Base
> (MySQL
> or Access - easily exportable to SQL Server or Oracle, if required), and
> generate a module to load the DB with the existing data from the file.
> This
> 'opens up' the closed COBOL file system, as the RDB can be accessed with
> standard software like Access, Excel, etc.
Yes, I have the source code and file definitions but I'm not a Cobol
programmer. I would like to be able to access them through the DLL that the
previous developer has written. I have that on another subject. "how to
export a Microfocus DLL with Delphi.
I could also use the conversion utility if you have an ODBC like connection.
I'm trying to access the DLL with Delphi but am having problems.
Stephen K. Miyasato
"Pete Dashwood" <dashwood@enternet.co.nz> wrote in message
news:<4odm6oFe8q5rU1@individual.net>...
>
> "Stephen K. Miyasato" <miyasat@flex.com> wrote in message
> news:45217f03$0$25775$ed962e05@news.felx.com...
> You can access these files with a COBOL program. They are not MicroFocus
> files; they are files written by the MicroFocus COBOL file system.
>
> If you are unable to write such a program (no COBOL software) you should
> use
> a utility to try and decipher the format and content of them ('Packrat'
> has
> been well spoken of here...). You can then write something in any of the
> popular languages to access them.
>
>
> If you don't have the source, you should brace yourself for pain...
>
> Pete.
>
>
>
>
>
>
Post Follow-up to this message"Stephen K. Miyasato" <miyasat@flex.com> wrote in message news:4521b80d$0$25776$ed962e05@news.felx.com... > > > > > > > > Yes, I have the source code and file definitions but I'm not a Cobol > programmer. Well, that is pretty crucial. Given that you have source, it will be possible to solve your problem relatively easily. > I would like to be able to access them through the DLL that the previous > developer has written. I can't really help with that, as I don't use MicroFocus and you haven't described what this .DLL is used for. > I have that on another subject. "how to export a Microfocus DLL with > Delphi. > I have some very limited experience with Delphi; it came down to fixing the generated Pascal... :-) > I could also use the conversion utility if you have an ODBC like > connection. The conversion utility generates a relational database, in third normal form, with table(s) that equate to the original COBOL definitions. Repeating groups (OCCURS) in the COBOL are normalized to separate tables, with the appropriate foreign key automatically set up. (REDEFINES is also catered for.) The DB created (or, it can generate to an existing Database), has all constraints and indexes in the original COBOL file(s) generated into it. The RDB can be accessed remotely or locally with ODBC, and it can be a MySQL or Access 2000 DB. (Either of these is easily exported to any other standard RDB that supports standad SQL - Oracle, DB2, informix, etc..) A COBOL program is simultaneously generated, which reads the original COBOL file(s) and writes their data to the RDB. As this is a COBOL source program you could edit it to do any specific processing you may require during conversion. You will, obviously, need a COBOL compiler to compile it before you can run it to load the data to the generated RDB. If you are talking about one file, I wuld be happy to do the conversion for you for free. I can't let you have the software for nothing, and it isn't worth buying it to convert one file. If you are interested in doing this... Send me: 1. The COBOL source. (That contains the file definitions and SELECTS). I'll send you back: 1. An empty Access (or MySQL) database that contains the data structure defined by the COBOL source on the file, normalized to third normal form. (If you opt for MySQL, I can include a complete set of CREATE TABLE statements that will create the database in any standard SQL environment.) 2. The COBOL source for a program that will read your existing data file and load its contents to the new Relational database. (You would need to compile it in your MicroFocus environment, then run it.) > I'm trying to access the DLL with Delphi but am having problems. Sorry, I can't help you with that. Pete. > > Stephen K. Miyasato > > > > "Pete Dashwood" <dashwood@enternet.co.nz> wrote in message > news:<4odm6oFe8q5rU1@individual.net>... > > > > > > > > > > > > > > > > > > > >
Post Follow-up to this messageStephen K. Miyasato wrote: > Is there a way to access the Microfocus Data file? ODBC? OLEDB? Is u need acces once, or regular? If regular then is u need it quick (actual data) or could wait some time until data exported (and maybe very very large file in output)? Is only once or not quick, the simple way: write export to CSV (comma separated values) program in COBOL. DISPLAY all fields comma separated, and redirect output to file (if microfocus allow output to standard output), or WRITE to LINE SEQUENTIAL text file. like this: ...... DISPLAY CUSTOMER-ID "," LASTYR-SALES "," LASTYR-PROFIT ...... and access this file by ODBC or OLEDB via MS Jet driver. IF u need it quick and actual, we have done OLEDB driver for COBOL datafiles, but for FUJITSU COBOL, think possible adopt this to microfocus. > > Stephen K. Miyasato
Post Follow-up to this messageSki, Would you be willing to see if this can connect to the Cobol fields from Microfocus? Is there anyway I can test it? Thanks Stephen K. Miyasato MDsync "ski" <t4na5nb02@sneakemail.com> wrote in message news:1160341139.311360.174400@b28g2000cwb.googlegroups.com... > Stephen K. Miyasato wrote: > Is u need acces once, or regular? If regular then is u need it quick > (actual data) or could wait some time until data exported (and maybe > very very large file in output)? > Is only once or not quick, the simple way: write export to CSV (comma > separated values) program in COBOL. DISPLAY all fields comma separated, > and redirect output to file (if microfocus allow output to standard > output), or WRITE to LINE SEQUENTIAL text file. > like this: > ...... > DISPLAY CUSTOMER-ID "," LASTYR-SALES "," LASTYR-PROFIT > ...... > > > and access this file by ODBC or OLEDB via MS Jet driver. > > IF u need it quick and actual, we have done OLEDB driver for COBOL > datafiles, but for FUJITSU COBOL, think possible adopt this to > microfocus. >
Post Follow-up to this messageStephen K. Miyasato wrote: > Ski, > > Would you be willing to see if this can connect to the Cobol fields from > Microfocus? > Is there anyway I can test it? You mean OLEDB driver? If yes, then not. I develop driver using fujitsu datafile access subroutines. I have no microfocus at all, and could only guess that microfocus have such routines too, and guess that possible rewrite driver for microfocus datafiles (or maybe using another way to access datafiles, forexample write access routine in mfcobol only for specified datafile). So, if you task is only one-time task and/or you could wait until data will be exported, then cheaper and simpler write cobol CSV export program. And then access that csv file via OLEDB, ODBC, etc.
Post Follow-up to this messagePowered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.