Hello everyone,
Does anyone knows any query expansion techniques that can be implemented using php other than hierarchical technique. i.e: facet , analysis, thesaurus.
By implementing query expansion, the users are not only presented with the keyword they inserted, but some related words to the keyword.

Thank you

Hello everyone,
Does anyone knows any query expansion techniques that can be implemented using php other than hierarchical technique. i.e: facet , analysis, thesaurus.
By implementing query expansion, the users are not only presented with the keyword they inserted, but some related words to the keyword.

Thank you

If you're implementing a search engine purely in PHP you're doing something wrong. Take a look at Apache Lucene or alternatives along those lines. PHP can but shouldn't.

Hello,
I have tried to do this bacic MySQl query expansion but there is an error..Could anyone who know how to correct it tell me. thank you

$myquery = "SELECT learningArea,subject,ability FROM lesson WHERE MATCH (learningArea,subject,ability) AGAINST ('".$_POST['q']."'  WITH QUERY EXPANSION);";

the error is like this
Query: SELECT learningArea,subject,ability FROM lesson WHERE MATCH (learningArea,subject,ability) AGAINST ('' WITH QUERY EXPANSION); Error: Can't find FULLTEXT index matching the column list.

I have this sybtax as well

$myquery =("SELECT * MATCH(learningArea,subject,ability) AGAINST ('$q' WITH QUERY EXPANSION) 
// AS score FROM lessonplan WHERE MATCH(learningArea,subject,ability) AGAINST ('$q' WITH QUERY EXPANSION) ORDER BY score DESC");

this error is shown.
Query: SELECT * MATCH(learningArea,subject,ability) AGAINST ('' WITH QUERY EXPANSION) AS score FROM lessonplan WHERE MATCH(learningArea,subject,ability) AGAINST ('' WITH QUERY EXPANSION) ORDER BY score DESC Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'MATCH(learningArea,subject,ability) AGAINST ('' WITH QUERY EXPANSION) AS scor' at line 1

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.