Hi, probably a newbie type question. Right now the query below searches
word.word_word field for hits. I want to add page.descrip and page.title
to the search and search these fields with LIKE '%$kewyord%' too. It
would be, if word.word_word OR page.descrip OR page.title LIKE
'%$kewyord%'. How would I add that optimumly to the SQL below? Thanks,
Lee G.
$result = mysql_query(" SELECT p.page_url AS url,
COUNT(*) AS occurrences, p.title AS title,
p.descrip AS descrip, p.page_id AS id
FROM page p, word w, occurrence o
WHERE p.page_id = o.page_id AND
w.word_id = o.word_id AND
w.word_word LIKE '%$keyword%'
GROUP BY p.page_id
ORDER BY occurrences DESC" );
Comment