full-text-indexing

mysql match/against

北城余情 提交于 2019-12-24 00:00:03
问题 I'm using this search -> match (c1, c2) against (">dg*" in boolean mode); and I get this list 1 dgas 2 dgica 3 dgicb 4 dgii 5 dgit 6 dgly 7 dgc 8 dgse which seems reasonable. The problem is that I DON'T get "dgl", which I know is there in column c1. So I DO get "dgly" but NOT "dgl". I find this confusing and would appreciate any thoughts. Thanks. 回答1: MySQL fulltext indexing will, by default, ignore words that are shorter than four characters. This can be changed at the server level by

How can I set up Solr to tokenize on whitespace and punctuation?

谁说胖子不能爱 提交于 2019-12-22 18:47:10
问题 I have been trying to get my Solr schema (using Solr 1.3.0) to create terms that are tokenized by whitespace and punctuation. Here are some examples on what I would like to see happen: terms given -> terms tokenized foo-bar -> foo,bar one2three4 -> one2three4 multiple words/and some-punctuation -> multiple,words,and,some,punctuation I thought that this combination would work: <fieldType name="text" class="solr.TextField" positionIncrementGap="100"> <analyzer type="index"> <tokenizer class=

MySQL MATCH AGAINST when searching e-mail addresses

…衆ロ難τιáo~ 提交于 2019-12-19 04:15:25
问题 I am writing a newsletter script and I need to implement searching in the addresses. I indexed the table with FULLTEXT but when I do a query such as: SELECT * FROM addresses WHERE MATCH(email) AGAINST("name@example.com" IN BOOLEAN MODE) I get strange results. It displays all emails on "example.com" and all emails with user "name". For example I get: john@example.com name@mail.net steven@example.com I rewrote the query to use LIKE "%name@example.com%" but for a big table it takes ridiculous

Warning: A long semaphore wait

≯℡__Kan透↙ 提交于 2019-12-18 12:17:36
问题 For the past 4 days I have had massive problems with my nightly updates , except for 1 night were it all went fine in between these 4 days. During these updates i update a couple of fulltext indexes. I do it in this manner. Drop the fulltext index Update the fulltext table Add the fulltext index This has been working perfect for over 2 years . Usual update time was around 3-4 hours which was normal for the amount of data that is updated each night. But since Friday really the update times has

Postgresql prefix wildcard for full text

感情迁移 提交于 2019-12-18 12:12:22
问题 I am trying to run a fulltext query using Postgresql that can cater for partial matches using wildcards. It seems easy enough to have a postfix wildcard after the search term, however I cannot figure out how to specify a prefix wildcard. For example, I can perform a postfix search easily enough using something like.. SELECT "t1".* FROM "t1" WHERE (to_tsvector('simple', "t1"."city") @@ to_tsquery('simple', 'don:*') ) should return results matching "London" However I cant seem to do a prefix

Faster search in Lucene - Is there a way to keep the whole index in RAM?

浪尽此生 提交于 2019-12-17 21:52:36
问题 Is there a way of keeping the index in RAM instead of keeping it on the hard disk? We want to make searching faster. 回答1: Is there a way of keeping the index in RAM instead of keeping it on the hard disk? Using the RAMDirectory class SampleUsage here Also from the Lucene FAQs ImproveSearchingSpeed Generally for faster indexing performance it's best to flush by RAM usage instead of document count and use as large a RAM buffer as you can. Also check this question: EDIT: RE: RamDirectory , As

Code first custom SQL migration timeout exception

老子叫甜甜 提交于 2019-12-17 19:12:19
问题 I am trying to create FULL TEXT index using Entity Framework Migration by executing custom Sql. My migration class looks like this: public partial class DocumentContentFullTextIndex : DbMigration { public override void Up() { AlterColumn("dbo.Attachments", "ContentType", c => c.String(maxLength: 260)); Sql("CREATE FULLTEXT CATALOG FullTextIndexes AS DEFAULT;", true); Sql(@"CREATE FULLTEXT INDEX ON [Attachments]( Content TYPE COLUMN ContentType Language 'ENGLISH' ) KEY INDEX [PK_dbo

How Can I view MySql Fulltext Indexes?

给你一囗甜甜゛ 提交于 2019-12-13 07:27:51
问题 Does MySql Fulltext search use indexing? If so, how can I view the Index entries table? I can view the Index Statistics with VIEW query. But, I just wanted to view the index record entries table. 回答1: Yes - FULLTEXT indexes, not regular indexes See Display Full-Text Index information I linked to the 4.1 MySQL docs, but you can pick the appropriate version in the upper left corner. 来源: https://stackoverflow.com/questions/1801715/how-can-i-view-mysql-fulltext-indexes

Sql Server 2008 Full-Text Index (characters issue)

那年仲夏 提交于 2019-12-13 01:17:20
问题 The Full-Text Index searching is working perfect but suddenly I noticed that it fails when it comes to some characters variance in Arabic In Arabic we have a trailing letter say {I} that can be written like { i } or { I } , It's the same letter but different ASCII code.. exactly like the English variance between { i } & { I } the "Contains" function can get "ALi" but not "ALI" both {ALi & ALI} exist.. {ALi} returns result but without the result of {ALI} {ALI} return 0 records when using full

Fulltext match() against() returning empty set

女生的网名这么多〃 提交于 2019-12-12 22:23:17
问题 I have a full text indexed table set up with the data Family in it. There is no White Space and the spelling is correct. How can I make this query match results as score and display them by score in DESC order? I keep getting empty set and don't know why. SELECT *, MATCH(MEDIA_TITLE) AGAINST('Family') AS SCORE FROM MEDIA_DATA_VIDS WHERE MATCH(MEDIA_TITLE) AGAINST('Family') ORDER BY SCORE DESC ; Any Help is Greatly Appreciated. 回答1: See https://dev.mysql.com/doc/refman/5.7/en/fulltext-natural