Support Forum

How can I clear data from database for watches?

KV kvr28
kvr28
Member

I installed the watch plugin the other day and for some reason like 200 members are showing up under users, watches by users, but they have not threads being watched, every time I try to delete them, I get errors like this and they are not removed from the list

[Mon Dec 01 12:29:00 2014] [error] [] WordPress database 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 '' at line 4 for query SELECT topic_id, topic_slug, topic_name, forum_slug
tttttt FROM rufus_sftopics
tttttt JOIN rufus_sfforums ON rufus_sftopics.forum_id = rufus_sfforums.forum_id
tttttt WHERE topic_id =  /* From [/index.php?sp_ahah=users-loader&sfnonce=a823108bc0&loadform=plugin&admin=sp_watches_admin_users&reload=watchuser&rnd=1417436941159] in [/wp-content/plugins/simple-press/sp-api/sp-api-wpdb.php:166] */ made by require('wp-blog-header.php'), wp, WP->main, WP->parse_request, do_action_ref_array, call_user_func_array, sp_ahah_handler, include('/plugins/simple-press/admin/panel-users/ahah/spa-ahah-users-loader.php'), spa_render_users_container, spa_plugins_user_form, call_user_func, sp_watches_admin_users, sp_watches_admin_users_form, sp_watches_render_user_watches, spdb_select, referer: /wp-admin/admin.php?page=simple-press/admin/panel-users/spa-users.php


[Mon Dec 01 12:29:00 2014] [error WordPress database 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 '' at line 4 for query SELECT topic_id, topic_slug, topic_name, forum_slug
tttttt FROM rufus_sftopics
tttttt JOIN rufus_sfforums ON rufus_sftopics.forum_id = rufus_sfforums.forum_id
tttttt WHERE topic_id =  /* From [/index.php?sp_ahah=users-loader&sfnonce=a823108bc0&loadform=plugin&admin=sp_watches_admin_users&reload=watchuser&rnd=1417436941159] in [/wp-content/plugins/simple-press/sp-api/sp-api-wpdb.php:166] */ made by require('wp-blog-header.php'), wp, WP->main, WP->parse_request, do_action_ref_array, call_user_func_array, sp_ahah_handler, include('/plugins/simple-press/admin/panel-users/ahah/spa-ahah-users-loader.php'), spa_render_users_container, spa_plugins_user_form, call_user_func, sp_watches_admin_users, sp_watches_admin_users_form, sp_watches_render_user_watches, spdb_select, referer: /wp-admin/admin.php?page=simple-press/admin/panel-users/spa-users.php

3 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

I think – although I can’t be sure – that the database error there is actually a bug we missed in the last release and if this is the case then it is fixed in an update awaiting release with the next WP 4.1. If that is the case apologies although I have not seen that particular form of the sql error while fixing the problem up. I think the issue is that there is nothing to delete. And the problem was that those rows should not be included in the query that populates the list.

I installed the watch plugin the other day and for some reason like 200 members are showing up under users, watches by users, but they have not threads being watched, every time I try to delete them, I get errors like this and they are not removed from the list

So what are wanting to do? If nobody has set any watches then there is no data to remove. If there is and you want to remove all of it then simply uninstall the watches plugin. Uninstalling always removes any associated data.

KV kvr28
kvr28
Member

I was just checking to see if anyone actually uses it, if not I was going to delete it, I don’t like having extra plugins if they are not being utilized, when I saw the list of users in the watches but no topics being watched, I thought it was another issue like we resolved yesterday

YS Yellow Swordfish
Yellow Swordfish
Member

It’s just the query. It included those with no watches by error. It is also painfully slow I believe – both of which will be resolved in the next update.