Genetic string searches Re: VChar vs VText

Ruslan Zasukhin sunshine at public.kherson.ua
Mon Nov 28 15:06:25 CST 2005


On 11/28/05 5:08 AM, "Ed Kleban" <Ed at Kleban.com> wrote:

>>> Either way, I'm sure glad I'm doing my searches on string hashes rather than
>>> actual strings.
>> 
>> Hashing can work only for search fld = "xxx"
>> 
>> But you cannot do range searches using hashing, right ?
> 
> Correct.  But now I'd like elaborate on an earlier note I made about a
> feature I'd like to see:
> 
> Of all the features on my wish-list for future Valentina versions, top of
> the list would be some VField.FindMasked functions; perhaps something like:
> 
> VField.FindMasked(
>     inMask as Integer, inKeep as Integer, inSelection as VSet )
>     as VBitSet
> 
> VField.FindMaskedAsArraySet(
>     inMask as Integer, inKeep as Integer, inSelection as VSet  )
>     as VArraySet
> 
> VField.FindFirstMasked(
>     inMask as Integer, inKeep as Integer, inSelection as VSet )
>      as Integer // Returns RecID
> 
> High-order bits of the inMask argument would be truncated to the size of the
> VField.  The inKeep argument would be one of:
> 
> EVKeep.includeExactMatches
> EVKeep.excludeExactMatches
> EVKeep.includePartialMatches
> EVKeep.excludePartialMatches
> 
> The functions would simply perform a BitAnd between the field value and
> inMask.  If the result was equal to inMask it would qualify as an exact
> match. If the result was non-zero it would qualify as a partial match.

Well, I believe you can get this right now, Ed in 2 ways:

1) using SQL and methods
2) using calculated fields and methods.

Valentina support a lots of functions. And I believe it support bit And.

So you can do something as:

    SELECT .. FROM T WHERE fld & mask

Or you can make Table Mathod -- calcualted field:

    fldM = t.CreateBooleanField( "name", "fld & mask" )

You can even index it.
And you can change formula on the fly.
And you can have many calculated fields for table...

Check docs on this feature


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list