How to Change MySQL FULLTEXT Index Minimum and Maximum Length of Words Como alterar o MySQL FULLTEXT índice mínimo e máximo da duração das palavras

MySQL database has built-in full-text search capability that allows SQL queries to perform search quickly using MySQL database engine. Banco de dados MySQL vem com capacidade de pesquisa de texto completo que permite consultas SQL para realizar pesquisa rápida de dados MySQL usando motor. The full-text search capability depends on the FULLTEXT index which is been created on various table fields or columns. A pesquisa de texto completo capacidade depende do índice FULLTEXT que é tabela foi criada em vários campos ou colunas. However, some search queries may not return the experted results or datasets, even though the data is verified to exists on full-text search, especially on short keywords or search terms. No entanto, algumas consultas de pesquisa não poderá voltar a experted resultados ou dados, apesar de os dados são verificados a existir a pesquisa de texto completo, especialmente a curto palavras-chave ou termos de pesquisa.

The problem probably lies on the default minimum length of words indexed by FULLTEXT index which is set as 4 characters. O problema provavelmente mentiras sobre o padrão de comprimento mínimo de palavras indexados pelo índice FULLTEXT que está definido como 4 caracteres. Thus, when attempting to search via full-text index, the short words are not indexed, and hance not return in search results. Assim, quando a tentativa de busca de texto completo através do índice, as palavras curtas não são indexadas, e não voltar hance nos resultados da pesquisa.

By default, the minimum value for length of word to be indexed in FULLTEXT index is four characters, while the default maximum length of words to be indexed in FULLTEXT index is varies depending on version of mySQL server. Por padrão, o valor mínimo para a duração da palavra para ser indexada no índice FULLTEXT é quatro caracteres, enquanto o padrão comprimento máximo de palavras a serem indexadas no índice FULLTEXT é varia dependendo da versão do servidor MySQL. To increase the number of words indexed and searchable, especially shorter words such as three-character words, administrator can reduce the minimum or increase the maximum length of words to be indexed by using ft_min_word_len and ft_max_word_len system variables. Para aumentar o número de palavras indexados e pesquisados, especialmente curtas palavras, como a personagem de três palavras, administrador pode aumentar ou reduzir ao mínimo o comprimento máximo de palavras para ser indexada, usando ft_min_word_len e ft_max_word_len sistema variáveis.

For example, for FULLTEXT index to index the three-character words, or 3-letter text, add in the following line to set the lower value for ft_min_word_len variable under [mysqld] section to an option file, ie my.cnf: Por exemplo, índice de índice FULLTEXT para a personagem de três palavras, ou 3 carta-texto, adicione a seguinte linha em conjunto com o menor valor para a variável ft_min_word_len sob [mysqld] seção para um arquivo de opções, ou seja, my.cnf:

[mysqld] [mysqld]
ft_min_word_len=3 ft_min_word_len = 3

Save the file, and then restart the MySQL server. Salve o arquivo e, em seguida, reinicie o servidor MySQL. After changing either value of full-text variable, which both affects indexing, the FULLTEXT indexes must be rebuilt. Após alterar qualquer valor da variável de texto completo, o que afeta tanto a indexação, os índices FULLTEXT devem ser reconstruídos. The following command to do a quick repair operating is sufficient to rebuild the indexes: O comando a seguir para fazer uma rápida reparação de funcionamento é suficiente para reconstruir os índices:

mysql> REPAIR TABLE tbl_name QUICK; mysql> REPAIR TABLE nome_tabela QUICK;

Note that each and every table that contains any FULLTEXT index must be repaired with SQL command above. Note que todos e cada tabela que contenha qualquer índice FULLTEXT devem ser reparados com o comando SQL acima. Also do not use myisamchk (unless you have also defined the full-text parameter values in [myisamchk] section) to perform the rebuilt as the full-text parameters are only known to mysqld server. Também não use myisamchk (a menos que você tenha definido também o parâmetro de texto completo em valores [myisamchk] secção) para executar o reconstruída como o full-text parâmetros só são conhecidos por servidor mysqld. If rebuild is not done, queries for the table may yield incorrect results, and modifications to the table will cause the server to see the table as corrupt and in need of repair. Se reconstruir não for feito, as consultas para a mesa maio conduzem a resultados incorrectos, e à alteração do quadro fará com que o servidor para ver o quadro como corrupto e que necessitam de reparação.

IMPORTANT : You're reading a machine translated page which is provided "as is" without warranty. IMPORTANTE: você estiver lendo uma máquina página traduzida que é fornecida "como está" sem garantia. Unlike human translation, machine translation does not understand the grammar, semantics, syntax, idioms of natural language, thus often produce inaccurate and low quality text which is misleading and incomprehensible. Ao contrário tradução humana, tradução automática não conhece a gramática, semântica, sintaxe, expressões idiomáticas da língua natural, assim, produzir muitas vezes imprecisas e de baixa qualidade texto que é enganosa e incompreensível. Thus, please refer to Assim, por favor consulte a original English article Inglês original article when in doubt. em caso de dúvida.



2 Responses to “How to Change MySQL FULLTEXT Index Minimum and Maximum Length of Words” 2 Responses para "How to Change MySQL FULLTEXT Índice Comprimento mínimo e máximo das Palavras"

  1. chichilatte
    May 11th, 2008 02:49 11 de maio de 2008 02:49
    1

    Yes, thnks, but where is this mysterious config file “my.cnf”? Sim, thnks, mas onde está essa misteriosa config file "my.cnf"?

  2. admin
    May 11th, 2008 08:21 11 de maio de 2008 08:21
    2

    Depends. Depende. Normally it’s located in /etc Normalmente ele é localizado em / etc

Leave a Reply Deixe uma resposta

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> Você pode usar estas tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime = ""> <em> <i> <q Cite=""> <strike> <strong>

Subscribe without commenting Subscreva sem comentar


Custom Search

Incoming Search Terms for the Article Incoming Termos de pesquisa para o artigo

mysql rebuild fulltext index MySQL reconstruir índices fulltext - -- mysql rebuild index MySQL reconstruir Índice - -- mysql minimum length MySQL comprimento mínimo - -- mysql index rebuild MySQL Índice reconstruir - -- mysql minimum word length MySQL comprimento mínimo palavra - -- mysql fulltext index length MySQL fulltext Índice comprimento - -- rebuild fulltext mysql reconstruir o MySQL fulltext - -- mysql text index length MySQL texto índice comprimento - -- rebuild fulltext index mysql recriar índices fulltext MySQL - -- mysql rebuild fulltext MySQL reconstruir fulltext - -- mysql rebuild full text index MySQL reconstruir texto completo índice - -- mysql update fulltext index MySQL atualizar fulltext Índice - -- mysql change index length MySQL mudança Índice comprimento - -- mysql fulltext length MySQL fulltext comprimento - -- length mysql comprimento MySQL - -- fulltext min chars fulltext min chars - -- mysql fulltext index MySQL fulltext Índice - -- fulltext search minimum length fulltext pesquisa comprimento mínimo - -- rebuild index MYSQL Índice reconstruir MYSQL - -- mysql change search minimum length MySQL mudança pesquisa comprimento mínimo - -- minimum word length fulltext comprimento mínimo palavra fulltext - -- mysql fulltext minimum word length MySQL fulltext comprimento mínimo palavra - -- fulltext index mysql fulltext Índice MySQL - -- mysql minimum search 3 chars help mysql pesquisa mínimo 3 caracteres ajudar - -- mysql full text search 3 chars mysql texto completo busca 3 chars - -- full text index mysql 3 letter words texto integral Índice mysql 3 palavras letra - -- update fulltext index mysql atualização fulltext Índice MySQL - -- mysql 3 letter fulltext MySQL 3 carta fulltext - -- mysql full text search minimum length 3 mysql texto completo busca de comprimento mínimo 3 - -- wm6 mysql wm6 MySQL - -- mysql maximum indexes MySQL índices máximos - -- how to change minimum word length for full text search in mysql alterar o modo de comprimento mínimo palavra para pesquisa em texto integral mysql - -- mysql fulltext ft_min_word_len MySQL fulltext ft_min_word_len - -- set mysql full text search minimum word length mysql conjunto pesquisa com texto completo palavra comprimento mínimo - -- mysql full text search min length mysql texto completo busca min comprimento - -- change mysql fulltext length mudança MySQL fulltext comprimento - -- all todos - -- mysql word length MySQL palavra comprimento - -- mysql index short words MySQL Índice curtas palavras - -- change mysql fulltext keyword length mudança MySQL texto completo palavra chave comprimento - -- rebuilding indexes in mysql reconstruir índices em MySQL - -- mysql full text index rebuild command mysql texto completo índice reconstruir comando - -- rebuild full text indexes mysql reconstruir texto completo índices MySQL - -- mysql fulltext short words MySQL fulltext curtas palavras - -- mysql fulltext MySQL fulltext - -- fulltext 3 letters mysql fulltext 3 letras MySQL - -- how to rebuild FULLTEXT indexes a forma de reconstruir índices FULLTEXT - -- fulltext minimum length fulltext comprimento mínimo - -- mysql fulltext search min 3 MySQL pesquisa fulltext 3 min - -- mysql search french words MySQL pesquisa francês palavras - --