I have a fulltext indexed table and try to query for results matching multiple words. E.g. I have a address table with the indexed columns address_text
, zip_code
and city
.
| ROW | address_text | zip_code | city |
| 1 | Bourbon street | 1234 | Baltimore |
| 2 | Bourbon street | 1234 | New Orleans|
Now I want to search for "Bourbon Baltimore" and only wants the first row.
I tried the following:
SELECT FT_TBL.* FROM ADDRESSES AS FT_TBL
INNER JOIN CONTAINSTABLE(ADDRESSES, *, '"Bourbon*" AND "Baltimore*"') AS KEY_TBL
ON FT_TBL.address_id = KEY_TBL.[KEY]
ORDER BY KEY_TBL.RANK, address_text
But it will not return any rows at all.