How to Change MySQL FULLTEXT Index Minimum and Maximum Length of Words Kaip pakeisti MySQL FULLTEXT Rodyklė Minimalus ir maksimalus ilgis Words
MySQL database has built-in full-text search capability that allows SQL queries to perform search quickly using MySQL database engine. MySQL duomenų bazė turi įmontuotą visą tekstą paieškos funkcija, kuri leidžia SQL užklausų atlikti paiešką greitai, naudojant MySQL duomenų bazės variklį. The full-text search capability depends on the FULLTEXT index which is been created on various table fields or columns. Visą tekstą paieškos funkcija priklauso nuo FULLTEXT indeksą, kuris buvo sukurtas dėl įvairių lentelės laukus ar stulpelius. 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. Tačiau, kai paieškos užklausose negali grąžinti experted rezultatus arba duomenų, nors duomenys yra patikrinti egzistuoja visą teksto paieška, ypač trumpo raktažodžius arba paieškos žodžius.
The problem probably lies on the default minimum length of words indexed by FULLTEXT index which is set as 4 characters. Problema greičiausiai yra pagal nutylėjimą mažiausias ilgis žodžius indeksuojamą FULLTEXT indeksas, kuris yra nustatytas kaip 4 simboliai. Thus, when attempting to search via full-text index, the short words are not indexed, and hance not return in search results. Taigi, bandant ieškoti per visą tekstą indeksas, trumpus žodžius nėra indeksuojami ir Hance negali grįžti į paieškos rezultatus.
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. Pagal nutylėjimą, minimali vertė ilgis žodis turi būti indeksuojami FULLTEXT indeksas keturių simbolių, o numatytasis maksimalus ilgis žodžiai turi būti indeksuojami FULLTEXT indeksas skiriasi priklausomai nuo versijos MySQL serveryje. 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. Daugiau žodžių ir indeksuoja paieškai, ypač trumpesnis tokių žodžių kaip trijų simbolių, žodžių, administratorius gali sumažinti minimalų arba padidinti Ilgiausias žodžiai turi būti indeksuojami naudojant ft_min_word_len ir ft_max_word_len sistemos kintamuosius.
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: Pavyzdžiui, FULLTEXT indeksas indeksas trijų simbolių, žodžių, arba 3-laiško tekstas, įtraukti į šią eilutę nustatyti mažesnės vertės ft_min_word_len kintamąjį pagal [mysqld] į pasirinktį failą, ty my.cnf:
[mysqld]
ft_min_word_len=3
Save the file, and then restart the MySQL server. Išsaugokite failą ir paleiskite serverį MySQL. After changing either value of full-text variable, which both affects indexing, the FULLTEXT indexes must be rebuilt. Po besikeičiančių arba vertė visą tekstą kintamųjų, kurie abu veikia indeksuojančią, kad FULLTEXT indeksus turi būti pertvarkytas. The following command to do a quick repair operating is sufficient to rebuild the indexes: Šią komandą, kad tai greitai remonto veiklos pakanka, kad būtų atkurti indeksus:
mysql> REPAIR TABLE tbl_name QUICK; mysql> REPAIR TABLE tbl_name SPARČIOJI;
Note that each and every table that contains any FULLTEXT index must be repaired with SQL command above. Atkreipkite dėmesį, kad kiekvienoje lentelėje, kurioje yra bet FULLTEXT indeksas turi būti pataisyta su SQL komandų aukščiau. 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. Taip pat nenaudokite myisamchk (nebent jums taip pat apibrėžė visą tekstą parametro vertes [myisamchk] skirsnis) atlikti przebudowany kaip visą tekstą parametrai yra tik žinoma, kad name serveryje. 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. Jeigu atstatyti nėra padaryta, užklausos lentelės galima gauti neteisingi rezultatai, ir pakeitimus lentelėje sukelti serverio žr. lentelę kaip sugadintas ir reikia remonto.
IMPORTANT : You're reading a machine translated page which is provided "as is" without warranty. SVARBU: You're reading mašina išverstą puslapį, kuri yra pateikiama "kaip yra" be garantijų. 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. Skirtingai nuo žmogaus vertimas, mašininio vertimo nesupranta gramatika, semantika, sintaksė, frazeologizm natūralios kalbos, todėl neretai netiksli ir žemos kokybės teksto, kuris yra klaidinančios ir nesuprantami. Thus, please refer to Taigi, prašome kreiptis į original English article originalas anglų straipsnis when in doubt. kai kyla abejonių.
Related Articles Susiję straipsniai
- MySQL Workbench - Visual Database Deign Tool Free Download MySQL Workbench - Visual Database teiktis įrankis Free Download
- Aqua Words Free Word Puzzle Game from Realore Studios at GAOTD Aqua Words Free Word Puzzle Game iš Realore Studios ne GAOTD
- 64-bit (x64) Windows Vista SP1 (6001.1800) tcpip.sys Auto Patcher to Fix Event ID 4226 and Unlock Increase Maximum Connections Allowed 64 bitų (x64) Windows Vista SP1 (6001.1800) tcpip.sys Auto lopytojas nustatyti Įvykio ID 4226 ir Atrakinti padidėjimas Maksimalus Jungtys Leidžiama
- How to Change the Display Language (Including Welcome Screen) in Windows Vista Kaip pakeisti ekrano kalbą (įskaitant Sveiki Screen) Windows Vista
- How to Change Icon of Shortcut in Windows Vista Kaip pakeisti Ikona Nuoroda į "Windows Vista"
- How to Activate or Change to Windows Vista Ultimate Extras Glass or Pearl Sound Scheme Kaip suaktyvinti arba Keisti į "Windows Vista Ultimate Kiti stiklo ar Pearl Garso sistema
- How to Change the Microsoft Office Excel Protect Sheet Password Kaip pakeisti programos Microsoft Office Excel Apsaugokite lapą Slaptažodis
- Download Windows Search 4.0 Preview Atsisiųsti "Windows Paieška 4,0 Peržiūrėti
- How to Enable PAE in x86 32-bit Windows Server 2003 and 2000 to Use Large 4GB or More RAM Memory Kaip įjungti PAE ir x86 32-bit Windows Server 2003 ir 2000 naudoti Didelės 4GB ar daugiau RAM atmintis
- Make Searches with Natural Language on Powerset Search Engine Padaryti paieška Natural Language dėl Determinizacja paieškos










































May 11th, 2008 08:21 Gegužė 11, 2008 08:21
Depends. Priklausomai. Normally it's located in /etc Paprastai jis yra aplanke / etc
May 11th, 2008 02:49 Gegužė 11, 2008 02:49
Yes, thnks, but where is this mysterious config file “my.cnf”? Taip, thnks, bet jei tai yra paslaptingas konfigūracijos failą "my.cnf"?