Home › Forums › Calendar Products › Events Calendar PRO › Out of Control Recurring Events Won't Delete
- This topic has 5 replies, 4 voices, and was last updated 9 years, 1 month ago by
Susan.
-
AuthorPosts
-
February 16, 2017 at 3:46 pm #1239261
Susan
ParticipantSomehow we generated over 75,000 bogus recurring events! They seem to contain no actual data and won’t delete. The majority display ‘(no title)’ as the title, the current date as the start and end dates, and no other info. Some list the title as ‘Unnamed Venue’, all else the same.
Each bogus event seems to have a unique post ID. (For obvious reasons I haven’t checked them all, but if I look at 20 they’re all different, in consecutive chunks of about 6 or 8.) When I look at the post slugs they repeat – several hundred events with identical slugs. The slugs are almost – but not quite – identical to events whose meta title was edited (through the Yoast SEO plugin) in the last week or two. An event whose slug is ‘commencement-5’ had its title edited from ‘Commencement’ to ‘2017 Commencement’ and meta title changed to Commencement – May 13, 2017, and several hundred of bogus events have the slug ‘2017-commencement’.
When I try to delete the bogus events the wheels go around, often for a long time. I never try to delete more than 20 at a time, that always crashes. Frequently the page times out. If it resolves, there’s a message that says “X posts deleted”, but the total number of posts hasn’t changed and there’s nothing in the trash. If I check the WP Optimize page, which lists the number of posts in the trash, that also shows nothing in the trash.
I checked the error log I have access to on the server, there are no Fatal Errors and nothing related to Tribe Events. I’m running the current versions of Tribe Events and Tribe Events Pro. I tried editing a couple of events on our local dev site to try to replicate the problem but didn’t get any. I can’t change the theme or turn off most of the plugins on the real site because it makes the site unusable.
PLEASE, how can I delete these 75,000 entries? I can go into our DB directly if that’s the only way and I know what to look for.
Thank you, Susan Paigen
February 17, 2017 at 3:44 pm #1240475Barry
MemberHi Susan,
Thanks for contacting us — that does indeed sound pretty alarming!
If you view the admin events list, do the duplicates show there and if you hover over the ‘edit all’ link, do you notice if they share the same post ID in the URL? For example, if the URL looks like this:
http://example.com/wp-admin/post.php?post=1205&action=edit
Then the ID would be 1205. If all (or most of) the Edit All links for this out-of-control set of events do indeed reference the same ID, we can probably craft a query to kill them all, along these lines:
DELETE FROM wp_posts WHERE ID = 12345 OR post_parent = 12345;
Where, of course, 12345 would be the actual ID in your case (you might use a tool like phpMyAdmin to run this query, if your host provides it).
Does that help at all? Of course, it is always sensible to make a complete backup before directly modifying database entries in this way.
Let me know how you get on or if you need further guidance.
February 20, 2017 at 8:46 pm #1242661Susan
ParticipantThey do not have the same ID. They have no title , start date , or end date , but they have unique IDs. I can’t tell what the ID range is because , when I view them in the admin , the ID numbers jump around. There will be maybe 6 or 8 in sequence , and then the next one will jump.
Is there a query to target blank title fields ?
February 21, 2017 at 12:14 pm #1243252Barry
MemberYes, that should be possible with something like the following snippet (once again, take the necessary precautions before running this! That is, back up and know how to restore the backup):
DELETE FROM wp_posts WHERE LENGTH( TRIM( post_title ) ) = 0 AND post_type = 'tribe_events'
March 15, 2017 at 9:35 am #1254548Support Droid
KeymasterHey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.
Thanks so much!
The Events Calendar Support Team -
AuthorPosts
- The topic ‘Out of Control Recurring Events Won't Delete’ is closed to new replies.
