Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

File Layout Question

Status
Not open for further replies.

acct98

IS-IT--Management
Aug 15, 2002
194
US
I have a *.DBF file and I am trying to find out the layout of the file so I can load it into Oracle. Does anyone know how to get the layout of a *.DBF file?
 
from the dBase command line, type modi stru (modify structure). this will show the layout. Also, you could browse the table and get the field names.

There's always a better way...
 
The above reply is the best way - from within dBase. Hey, other programs such as FoxPro, etc. can also read the fields. If you do not have access to dBase, then you may have to "look under the hood" at the nuts and bolts of the file. Not easy to do since if you get out of synch, you can mis-read something. If know how to look at the table byte by byte, then you can use these technical resources:

faq182-3161
 
Just thought of something... if you don't have dBase, FoxPro, etc. you can open the dbf file in Excel!

Start Excel, click File->Open. Select dBase files (*.dbf) in the File Type at the bottom of the File Open window. Navigate to the directory where your DBF files are located and select the one you want. Excel will take it from there by placing the field names in seperate cells across the spread sheet with the field data in the rows beneath each field name!

Note: you may have to expand the column widths to read the field names correctly.

There's always a better way...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top