I would like to make a contribution public, it uses fulltext indexes on products_description name and description fields to allow relevance ordered search results.

The code is working fine (an observer), but I am not sure if my current method to add and drop the indexes is right.

I create the indexes transparently the first time the observer is run (on the first search after installation). This takes a while on big catalogs, but allows for very easy installation (no need to manually run SQL which confuses a lot of users).

And I still don't know how to drop the indexes if the user wants to uninstall the whole thing. My first thought was to give the SQL statements for copy/paste on the admin>tools>sql patches, but seems to fail, with no messages. Is it perhaps disallow to run DROP statements from there? Should I better provide a PHP script for all DB modification ? An admin page?