DATABASE FILES

The basic type of files which Star4Win generates and works with are database files, with a usual extension .dbf. These files are generally compatible with widely used software products like dBASE III+, dBASE IV and FoxBase. Star4Win database files, however, have their own peculiar features. In order to explain them, we have to dwell in some detail on databases in general.

A database file (sometimes called electronic table or a spreadsheet) is a table-like structure consisting of a certain amount of records ( = lines), each record being subdivided into fields ( = columns). The number, types and names of fields are fixed and can be changed only by means of a special procedure (called "modifying structure"), whereas the number of records is optional and can be easily increased or decreased by the user. The fixed structure of the database files allows for a very quick access to all records even in huge databases.

Fields in a database file can belong to several types, serving different purposes. Standard dBase files have five basic field types:

Character fields
For input of all kinds of character information.
Numeric fields
For numbers only.
Date fields
For dates only.
Logical fields
For binary logical input (these fields may only contain the information "Yes"/"No" or "True/False")
Memo fields
For input of character (memo) information.
While the first four field types have fixed field length (a maximum of 255 symbols for character fields, 15 symbols for numeric fields; always 1 symbol for logical fields and 6 symbols for date fields), memo fields have no field boundary. Still I do not recommend to use memo fields (however convenient they seem) for the following reason.

Memo fields in standard dBase are, in fact, not fields in the strict sense of the word. The database itself contains only numeric pointers to the field information contained in a separate file (with a standard extension .dbt). These numeric pointers themselves occupy special fields (10 bytes long for every memo field) within the .dbf file. Once you input anything (even 1 symbol) into a memo field within a certain record, a standard block of 512 bytes is added to the .dbt file - and most of these 512 bytes remain unused. On the other hand, if you edit an already occupied memo field and cross the 512-byte boundary, the whole content of the field is overwritten in two 512-byte blocks which are then added to the end of the .dbt file - while the old 512- byte block stays in its original place (although it is not being used any more). All this results in the fact that .dbt files may grow even longer than .dbf files.

Star4Win supports all the original dBase field types, which means that you can safely view and edit original dBase files while working with Star4Win. It has, however, its own specific features: