WordPress.org

Ready to get started?Download WordPress

Forums

Relevanssi - A Better Search
[resolved] Relevanssi not logging searches (11 posts)

  1. VFHwebdev
    Member
    Posted 1 year ago #

    Been running Relevanssi for a while now and decided to go see what I could learn from looking at user searches. It doesn't appear to be logging user searches even though I have that option checked.

    The table on the User Searches dashboard shows the following:

    Today and yesterday 0
    Last 7 days 0
    Last 30 days 0
    Forever 281

    Nothing appears under Common Queries or Unsuccessful Queries.

    Any suggestions?

    http://wordpress.org/extend/plugins/relevanssi/

  2. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    Sounds like an update that didn't upgrade the log database. Your log database has the wrong format, so Relevanssi can't write to it.

    Try to deactivate and reactivate the plugin to see if it helps. You can also take a look at the database with phpMyAdmin or similar to see if it has an 'ip' column. If it doesn't, you can add it manually (it's a varchar(40) column).

  3. VFHwebdev
    Member
    Posted 1 year ago #

    I don't see an 'ip' column in any of the relevanssi tables and deactivating and reactivating didn't seem to create one.

    So I added a column as you described to the table relevanssi_log.

    I'll give it a day and see if it starts working. Thanks for the help.

  4. VFHwebdev
    Member
    Posted 1 year ago #

    That didn't seem to have any effect. I've run a couple searches (even logged out to make sure I wasn't being filtered as a logged in user) and they're not showing up in the log.

    I downloaded a fresh copy of the plugin, uploaded it to my web server, then deactivated and reactivated the plugin. It's still not working. Any other ideas?

  5. VFHwebdev
    Member
    Posted 1 year ago #

    Don't know if this helps but it looks like my sites that were recording logs all stopped around 7/17/2012.

  6. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    The logging stopped, because after the update the IP column was required and it is missing.

    If it doesn't work with the correct database table, then I don't know what is the problem. Make sure the logging is enabled, that the option hasn't been turned off accidentally for some reason.

  7. VFHwebdev
    Member
    Posted 1 year ago #

    Just to be sure I'm putting the column in the right table, the ip column goes in the relevanssi_log table right?

  8. VFHwebdev
    Member
    Posted 1 year ago #

    Ok, I think I worked it out. I found another one of my sites where search logging was working and compared the tables.

    In the relevanssi_log table there were a number of changes I needed to make in addition to creating the ip column mentioned above.

    I also needed to change id from tinyint to bigint and add a user_id (bigint(20)) column.

  9. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    Oh, ok, forgot the user_id column was changed as well. Glad to hear you figured it out.

  10. compukol
    Member
    Posted 1 year ago #

    Can you please post the correct structure of Relevansii tables so we can all fix this problems?

  11. Mikko Saari
    Member
    Plugin Author

    Posted 1 year ago #

    You can find the correct database structure for the current version from the plugin files (see lib/init.php which is responsible for installing the database tables).

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags