德比:全文搜索

时间:2015-07-30 14:43:51

标签: search text derby

我有一个超过2500,000条记录的巨大数据,分布在德比的10个表中。有两列" floraNfauna"和"地点"在每个表中都很常见。现在我必须找到一个特殊的植物群NEGuna"发现在特定的"位置",所以我使用"选择"查询"喜欢"例如"从floraNfauna喜欢('%fish%')和('%浅水体%')"等位置的表中选择*;并且需要几天才能最终获取有时低于1000的结果。搜索后我发现"全文搜索"将是最好和更快的方法。你能帮我举个例子吗?

2 个答案:

答案 0 :(得分:0)

Derby与Lucene很好地集成,Lucene是一个全文搜索引擎。

在此处详细了解:http://wiki.apache.org/db-derby/LuceneIntegration

答案 1 :(得分:-1)

Firstly you must consider indexing your table. Here is an SO link which definitely would help to know more about Why to index a DB table.
More about Adding Indexes to a table.

Secondly, if you are using a centralized database, then definitely consider upgrading your server hardware configuration.

Thanks, hope it helps.