Technical Note #3
Title: To Search Where No One Has Searched Before Last Revised: 5/30/93
Description: Setting Key Fields to allow you to easily use Form Searching to find different data.
The benefits and drawbacks of Key Fields.
When you use the Form Search capability of PackRat 5.0, you may notice that some of the
fields on the form you are searching are grayed (not selectable). These fields are grayed
because they are not defined as Key Fields. By carefully using the Form Editor, you can make
them into Key Fields (and therefore searchable fields). However, doing so may have its
Creating Key Fields
Let's begin by finding out how to create a Key Field. then, we will discuss the benefits and
Key Fields are created in the Form Editor. Existing fields can be turned into Key Fields (or have
their Key Field status taken away). To access these options, choose the Fields button from any
of a number of places in the Form Editor. At the subsequent dialog, choose to edit a field.
You will notice, when editing a field, that the Indexing Group Box contains the check boxes: Key
and Global. The box we are concerned with here is the Key check box. If the box is checked, the
field is a Key Field. If it is not checked, then, well, you can guess. If you set a field to be marked
as Key, it will be available during a form search.
Benefits of Key Fields
This one is pretty obvious. If you have a field which is a Key field, it will be available during Form
Searches. If you need to quickly access records based on the data in a specific field, you should
make that a Key Field.
Drawbacks of Key Fields
When you set a Key Field, it becomes "indexed". In technical terms, this means that the
database index file is expanded to include any records with this field. In simpler terms, it means
that your database will take up more space. How much space depends on how many records you
have in your database. Another key field on a form you rarely use may take up little space. If it is
on a form which has thousands of records, it may take up a large amount of space.
Simple Rules of Key Fields
Before setting a field to Key, ask yourself the following two questions. If the answer to both is not
an emphatic "Yes", then you probably should NOT set the field to Key.
1. Do I often need to find data based the contents of this field?
2. Is using the full search dialog too complex or take too long for finding data in this field?
Packrat 5.0 Technical Notes Page #: 1 Tech Note #3