Contact
Manager - Filtered Indexes
Databases
get large. They get cumbersome. Rarely ever will you want to look
at every record in your database. Most of the time you will want
to break it down into smaller pieces so that it is easier to manage.
You might need to look at all the records in a particular state,
or a particular zip code, or any number of other categories. The
means by which these records are grouped is called a Filter. Filters
are very powerful tools. Without them, you would have to sort
through every record in your database trying to find the records
you want to look at. Filters do this for you. They look at every
record in your database and see which ones meet the criteria you
have set aside for a group. Sometimes however, it can take a little
time to process that much information. After all you are looking
analyzing every record in the database, even if you aren't looking
at all of them.
The way a filter works is pretty simple. When you create a filter,
you establish some criteria that determine what records you want
to view. For example, state = "TX". The filter looks at the first
record in the database and checks the state field to see if it
equals "TX." If it does it includes that record in the filter.
If it does not equal "TX," then it ignores the record and goes
on to the next one and checks it. This process happens quite fast,
but can still take anywhere from a few seconds to a couple of
minutes, depending on the size of the database. Now, there's another
factor here. Earlier, we referred to the "next record" in the
database. What that record is can vary. What determines the "next
record" is the Index.
The
index is how your database will be sorted. If your index is on
the state field, then all the records in your database will be
organized alphabetically by state. Wouldn't it be great if you
could combine a filter, with an index so that all your "TX" records
were together and the program wouldn't have to look through the
entire database in order to filter out only those records? Well
you can. They are called Filtered Indexes.
Combining indexes with filters can dramatically
improve the access time when using filters in the contact manager,
or when generating reports and quick lists. It does this by grouping
together the records that are going to be filtered. That way,
when TeleMagic looks at the "next record" in the filter, they
are already sorted. In our example of filtering on "TX," all the
Texas records will be together. It includes all these records.
When it gets to the "next record" that is not in the filter, it
stops looking. That way it doesn't have to look at the entire
database.
There are a couple of criteria for the filters that can be used
in conjunction with an index. First, the filter must be a simple
filter and second, the fields the filter is using must be on the
same level you are indexing on. When you create an index, you
will have an option to attach a filter to it. That list will show
you which filters can be selected. You can also edit an existing
index and attach a filter to it. For additional help on creating
filters and filtered indexes, see your online documentation
--
End of FAQ #550