Subject | Re: [Firebird-Architect] Long strings and approximate indexes |
---|---|
Author | Ivan Prenosil |
Post date | 2005-03-10T17:34:34Z |
> We may be able to do the same thing with long strings. Firebird 2Perhaps the maximum length could be configurable for each index
> doesn't need to limit the index key at all, just truncate it at the
> maximum length that can be supported for the current page size, after
> the key is built, but before prefix compression.
(to some lower value than permitted by ODS), otherwise
for some data you could end up with one index entry per page. ?
Also, would such index be flagged as not suitable for ordering ?
Ivan
----- Original Message -----
From: "Ann W. Harrison" <aharrison@...>
To: <Firebird-Architect@yahoogroups.com>
Sent: Thursday, March 10, 2005 6:14 PM
Subject: [Firebird-Architect] Long strings and approximate indexes
>
> Firebird has what could be called "approximate" indexes. The fact
> that a value appears in an index doesn't guarantee that the value is a
> legitimate part of a result set. The normal case where a value appears
> in the index but not in the result set is that the value is associated
> with a record version that's not appropriate in the current transaction.
>
>
> But there are cases where the value in the index is only approximately
> right. Most numeric values are converted to double precision floating
> point for indexing. This allows a the scale - or length - of the field
> to change without invalidating the index. It does, however create a few
> cases where the index key is only approximately the same value as the
> value in the record. Since the index handling code is already set up to
> check the actual value presented against the actual value in the record
> version being retrieved, these mismatches are recognized.
>
> We may be able to do the same thing with long strings. Firebird 2
> doesn't need to limit the index key at all, just truncate it at the
> maximum length that can be supported for the current page size, after
> the key is built, but before prefix compression.
>
>
> Regards,
>
>
> Ann