Topic: Help Deleting Users With 0 Posts and Last Login More Than 1 Yr Ago

The administration area doesn't quite offer the search I am after to delete users by 0 posts and last login more than 1 year ago.  I believe, however, that the last login information for users is stored in the database, so this should be possible using a SQL query in phpMyAdmin or by an extension.

If someone has some help or input to offer, I would appreciate the time it would save me to figure it out.  smile

2

Re: Help Deleting Users With 0 Posts and Last Login More Than 1 Yr Ago

DELETE FROM punbb_users
WHERE num_posts=0 
AND last_visit<$time

Where

$time = time()-60*60*24*365;

Maybe better back up your users table first, too :-)