Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread full text search in elevatedb
Wed, Jul 29 2009 12:08 PMPermanent Link

"Paul Chen"
I used to be able to use TextIndexFields to find all the fields with full
text index and then build the query in DBISAM. Now with ElevateDB, the
property TextIndexFields now longer exist. How can I find all the data
fields with full text index and build a query accordingly?

Paul
Wed, Jul 29 2009 12:43 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Paul,

<< I used to be able to use TextIndexFields to find all the fields with full
text index and then build the query in DBISAM. Now with ElevateDB, the
property TextIndexFields now longer exist. How can I find all the data
fields with full text index and build a query accordingly? >>

You can find this information out by querying the system Information.Indexes
and Information.IndexColumns tables:

http://www.elevatesoft.com/manual?action=mantopic&id=edb2sql&category=3&topic=68

http://www.elevatesoft.com/manual?action=mantopic&id=edb2sql&category=3&topic=69

You can find all text-indexed columns for a particular table with this
query:

SELECT *
FROM Information.Indexes I
INNER JOIN Information.IndexColumns IC ON I.TableName=IC.TableName
WHERE I.TableName='MyTable' AND I.Type='Text Index'

--
Tim Young
Elevate Software
www.elevatesoft.com

Wed, Jul 29 2009 9:39 PMPermanent Link

Paul
Tim, Thank you for the tip. But the SQL you wrote is not 100% right. The correct SQL
should be:
SELECT *
FROM Information.Indexes I
INNER JOIN Information.IndexColumns IC ON I.TableName=IC.TableName
WHERE I.TableName='bib' AND I.Type='Text Index' AND I.Name=IC.IndexName

Thanks, Paul
Thu, Jul 30 2009 1:10 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Paul,

<< Tim, Thank you for the tip. But the SQL you wrote is not 100% right. The
correct SQL should be: >>

You are correct.  But, actually the best way that is 100% optimized is this:

SELECT *
FROM Information.Indexes I
INNER JOIN Information.IndexColumns IC ON I.TableName=IC.TableName AND
I.Name=IC.IndexName
WHERE I.TableName='bib' AND I.Type='Text Index'

EDB won't optimize join conditions in the WHERE clause, ala SQL-89 style.

--
Tim Young
Elevate Software
www.elevatesoft.com

Image