Get data from *.dbf and *.cdx and *.fpt into access

aubie8
aubie8 used Ask the Experts™
on
First let me say, I am no DBA!!!  My coding experience is more with VB and Lotus Notes and Lotuscript.

What I have is soem dbf, cdx and fpt files that have data that I need to extract and put into an MS Access file.  I have done some of the dbf files, but I do not know how to get the corresponding .cdx or fpt data associated with the dbf.

Can anyone tell me how to do that?  Also, will it have table links to identify the information that goes with the dbf file?

thanks!

chris
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Vitor MontalvãoIT Engineer
Distinguished Expert 2017

Commented:
Hi Chris,

cdx are index files for dbf.
fpt I don't know, but can be FoxPro?

If you only need data, I think that dbf file are what only you need!

Good luck,

Vitor Montalvao

Author

Commented:
i will say this...  ive opened up the fpt files with notepad.  i can see ALOT of text but some garbage looking characters too, and it looks like data.  From other reading I've done it said fpt files are memo data.  So, I really need to get to this data as well.

What do you mean exactly when you say index files?

chris
Vitor MontalvãoIT Engineer
Distinguished Expert 2017

Commented:
As you should know, dbf save only data.
If you want to create index for that table, it would create an index file (idx) for each index relative to the table.
But FoxPro evaluate that indexes files to an unique cdx file (collection of index) relatives to a table.

Your ideia for fpt files maybe's right.
You can confirm that, opening the structure of a dbf file in MS Access, and look for a memo field.

Good luck,


Vitor Montalvao
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

Commented:
Aubie8,

Fpt fles ...is used by FOXPRO to keep the data from memo fields

I.e if you got a foxpro table .. table1.dbf with some memo field in it.. content of this memo field will be kept in table1.fpt..

If you need to extract data from Foxpro to MS Access ...you basically only need the dbfs..

If you need to know what the cdx are for.. you need to check the table structure from foxpro.. this will give you an idea of the indexes which has been created on that particular table..

How are you doing the conversion??.. because I think you may get some problem to transfer the data in the memo fields.. !! ..

Please let us know if you need more help

Lichien


Author

Commented:
Thanks for the information Lichien.

I have gotten the data from the dbfs into access, but I still need the info from the memo fields.  You don't know of a way to extract that into a table in access just from the file?  

Lets say I had foxpro.....  Is there a way to export that data into a form that I could then load it into access?

Thanks for the help.

Chris
Commented:
Chris,

How are you converting your dbfs into access.?

I dont know your timescale for doing this conversion..but quite recently had to get some sort of report in excel format.. to get around the memo field import problem,. I've extracted the string from the memo field in bunch of 250 chars.. because I was transferring them to a temporary foxpro table.. but in my case.. I knew there wont be more than 5 lines in the memo fields..

How about yours.. is your memo field containing loads of information..??

In foxpro..you can also return specific lines from MEMO field using the MLINE() command.. and MEMLINES() to get the total number of lines in the memofield...

I think first thing will be to have an idea of the size of data that you need to convert...

if you have got foxpro.. you can type the foll. command in the command window

select max(memlines(memofieldname)) from yourtable

this will give you the maximum number of lines in the memo field.

We'll also need to know the size of your dbfs.. because you dont want to do something thats going to take ages to extract.

Important infor ..also..needed is version of Foxpro you've got..

Anyhow.. let me know the details.. or if you need more help..

Lichien..
(p.s: feel free to contact me on roy_ittoo@hotmail.com)


Author

Commented:
i tried to send you an email.  not sure if it went.  please let me knwo if you got it.

chris

Author

Commented:
Didn't really answer what I wanted to do, but has helped me in a round about way find something that might work.  Thanks for your help Lichien.

Chris

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial