Thanks for this, very useful!
When I imported the product, it didn't create the table 'rq_recent_queries'. I don't know why.. when I ran the SQL from the .xml file manually I got an error from MySQL. Maybe it's an old version (4.0.25)?
Well, I created the table manually and just copied the structure from the search-table over as that's what I assumed the SQL should have done.. then reimported the product and now it works!