How to Create a DBF File
With DBF Viewer 2000® you can create a new DBF file in dBase III/IV, dBase Level 7, FoxPro or Visual FoxPro format in a few minutes: add fields, set their types and sizes, choose the file type and save the table. For automation, the same can be done from the command line.
Creating a New Table in DBF Viewer 2000
Step 1. Open File | New
The New DBF file dialog box opens.
Step 2. Add fields: name, type, and size
Click "New field" and fill in Field, Type, Size and Digits. Use "Delete" to remove a field, "Import" to copy fields from another DBF file, and the arrow buttons to change their order.
Step 3. Save the file
Click OK, enter the file name in the Save As dialog and click Save button.

Create DBF File via Command Line
Create file in dBase III format
"c:\Program Files (x86)\DBF Viewer 2000\dbview.exe" /create:d:\DBF\myfile.dbf /fields:ID:N10,NAME:C20,MYDATE:D
Create file in Visual Foxpro format
"c:\Program Files (x86)\DBF Viewer 2000\dbview.exe" /create:d:\DBF\myfile.dbf /fields:ID:N10,NAME:C20,MYDATE:D /VFP
Create database in dBase Level 7 format
"c:\Program Files (x86)\DBF Viewer 2000\dbview.exe" /create:d:\DBF\myfile.dbf /fields:ID:N10,NAME:C20,MYDATE:D /dbase7
Create file with fields from text file
"c:\Program Files (x86)\DBF Viewer 2000\dbview.exe" /create:d:\DBF\myfile.dbf /fieldslist:myfields.txt
Frequently Asked Questions About Creating DBF files ▼
Which DBF formats can I create? ▼
dBase III/IV, dBase Level 7, FoxPro and Visual FoxPro.
Which field types are supported in a new DBF file? ▼
You set the type for each field in the New DBF file dialog; the list of available types depends on the selected file format.
Can I copy fields from another DBF file? ▼
Yes. Click "Import" in the New DBF file dialog to append fields from another DBF file.
Can I create new tables from the command line? ▼
Yes. Use the /create command with the list of fields or with a text file containing the fields; examples are given above.
See also: DBF to Excel, DBF to SQL, DBF to CSV, Filtering records, Sorting records in dbf file, Command line options