Mysql does not employ indexes, haulage out LIKE ' %blablablabla % ', and apparently, could. other shortly... I did not spend tests, except ideas I shall depict below.
The index is under structure simply:
1. Are "shingl", only not through words, and under correspondence . For case , "shingl" - hash 5-ти signs .
2. At hunt undertake шинглы that, %what is between cipher on percent of %
3. All recordings into the stand in which is similar shingl and provided that on that table through heshes it is already possible to impose a normal catalog that within known hesh to explore quickly are searched;)
4. Having narrowed part of investigate , having eliminated those recordings in which there are no sites which enclose a like set shingl, it is previously possible to be hurry quickly on recordings, by usual algorithm.
Such index can be not reconstructed habitually too regularly . In this case through search on хешам worn the optimized algorithm, plus by seek on nonindexed colums, it is promising to pass in the old mode , that however will be faster, than an elderly method to go on all support .
As a variant of realization lacking intervention within code MySQL, it is promising to struggle to reinstate design LIKE ' %blablablabla % ' on something nearer to into (search about a presence(ruling ) of the necessary recordings on presence necessary hesh's).
plausible , what to optimize LIKE inside which 2 symbols, framed it is familiar percent(attention ), it willpower be tricky , but I think, that examples when it is interpellated and a semi of the offer during LIKE, it is a lot of and here already is what to optimize. within addition inside languages there are normal separators;) - seldom worn letters, rarely used combinations of mail , etc. I Think, what is it too it is likely to apply somehow.
It is likely to build an catalog on the basis of beforehand positive separators, and then to analyze approximating on conformity to environment of the optimized search. As objects (it is not confident on 100 % bar as a variant) family of stretched words can act. qualification even 50-60 % spirit be passed out on the optimized branch of algorithm it already motivation be rather quite good parameter.
tranquil an suggestion . If to use a technique described in the beginning it is essential to appear average extent of the text which gets between %... %. And to store(maintain ) shingl taken with combinations of correspondence in the length equivalent to usual length of the copy , getting within LIKE because I realize , LIKE has algorithm of search abserds insideabsers , but is not confident, what exactly for this use it(him) exploit more regularly .
In count :
I did not look code MySQL but as far since I understand, at LIKE all recordings are looked through. proviso LIKE to combine with IN in which nearby will be a record of recordings on which to spend LIKE it will capitulate the fruits. It any additional absolutely the index, is base of attributes.
case :
If to enter attributes of the text, for example, attributes "tstv", "nkc", "ngl", "ntstc" (extraordinary enough combinations of mail , but on the convinced diligence of them it it is possible to type(amass ) enough) on the beginning of quite short texts it is possible to eliminate at once up to 80 % of recordings condition inside LIKE there is a identical combination, thus considerably thinning area of search. Let even on the staying recordings it is basic to exceed usual algorithm, on полумиллионе recordings usual LIKE will fix together ласты to the server, approximating on previously filtered put of recordings it self-manage be lope on 1-5 thousand recordings, that the server does(makes) easily enough yet at loading.
like tactics can work, when inside resembling there are often second-dispense combinations of letters, plus we cover base of attributes of texts within which the often positive combinations of letters achieve not convene .
Search of rare and often combinations of correspondence , and too is adaptive to adjust algorithm on the beginning of data of actual texts with searches to them, it is potential to take out during background when it unloaded processes
The analysis of language or symbols of "additional " language can fairly help with the maintenance(inside ) of fields. For example, I have countryside in which the nickname of job is stored(kept). condition I shall put an attribute " percent(curiosity ) of latin symbols " I can safely reject folks recordings somewhere the percent(awareness ) of latin symbols into recording motivation be less, than percent(concentration ) of latin symbols during search.
It turns out, that the algorithm of concert LIKE is necessary treeing, and at show of the search within addition near spend the analysis of that inside LIKE. into pcre because far since I remember, nearby is such concept completing plan, to shows algorithm of a presence(decision ) of accord or inconsistency , which on his(its) often use keshering, doubtless , knowingly:)

|