List Info

Thread: MATCH AGAINST help




MATCH AGAINST help
user name
2006-08-09 17:56:09
I want to do the equivalent of

SELECT id from TABLE WHERE text='text'

only fast solution I found is:

SELECT id,text from TABLE WHERE MATCH(text)
AGAINST('value' IN BOOLEAN
MODE) HAVING text='value'

Is there a better way to do that? Cause using having needs
me to add a
column in select wich is a problem in some cases.

It has to return the EXACT WORD MATCH. so only rows
containing the
exact "value" content in the text column will be
returned.

thanks


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "PHP & MySQL" group.
To post to this group, send email to phpmysqlgooglegroups.com
To unsubscribe from this group, send email to
phpmysql-unsubscribegooglegroups.com
For more options, visit this group at http://groups
.google.com/group/phpmysql
-~----------~----~----~----~------~----~------~--~---

MATCH AGAINST help
user name
2006-08-10 08:37:23
Whats the problem with this query anyway ??

SELECT id from TABLE WHERE text='text'





jmichel wrote:
> I want to do the equivalent of
>
> SELECT id from TABLE WHERE text='text'
>
> only fast solution I found is:
>
> SELECT id,text from TABLE WHERE MATCH(text)
AGAINST('value' IN BOOLEAN
> MODE) HAVING text='value'
>
> Is there a better way to do that? Cause using having
needs me to add a
> column in select wich is a problem in some cases.
>
> It has to return the EXACT WORD MATCH. so only rows
containing the
> exact "value" content in the text column
will be returned.
> 
> thanks


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "PHP & MySQL" group.
To post to this group, send email to phpmysqlgooglegroups.com
To unsubscribe from this group, send email to
phpmysql-unsubscribegooglegroups.com
For more options, visit this group at http://groups
.google.com/group/phpmysql
-~----------~----~----~----~------~----~------~--~---

MATCH AGAINST help
user name
2006-08-10 13:04:22
since my field is FULLTEXT, doing just that, is EXTREMELY
slow
this is why I do HAVING so it does it only on a result under
10 rows or
so.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the
Google Groups "PHP & MySQL" group.
To post to this group, send email to phpmysqlgooglegroups.com
To unsubscribe from this group, send email to
phpmysql-unsubscribegooglegroups.com
For more options, visit this group at http://groups
.google.com/group/phpmysql
-~----------~----~----~----~------~----~------~--~---

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )