Current time: 04-19-2014, 07:33 PM Hello There, Guest! (LoginRegister)


Thread Closed 
 
Thread Rating:
  • 3 Votes - 2.33 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Common SQL Queries post Merge
12-14-2010, 03:31 PM (This post was last modified: 12-01-2011 10:06 PM by Dylan M..)
Post: #1
Solved: 3 Years, 4 Months, 3 Days, 4 Hours, 1 Minute, 27 Seconds ago Common SQL Queries post Merge
I'll keep this updated as often as new Queries are needed.
Please remember to change "mybb_" in these queries to whatever your prefix actually is.

All PMs are "Unread"
Code:
UPDATE `mybb_privatemessages` SET `readtime` = '1' WHERE `readtime` = 0 AND `folder` != 2;
UPDATE `mybb_privatemessages` SET `status` = '1' WHERE `status` = 0 AND `folder` != 2;

Replies Count is Off and/or Threads with 1 post are showing 1 reply instead of 0
Code:
UPDATE `mybb_threads` t SET firstpost=(SELECT MIN(pid) FROM `mybb_posts` p WHERE t.tid=p.tid)

All Postcounts 0
Code:
UPDATE `mybb_forums` SET `usepostcounts` = '1';

PHP Error When Viewing Profiles
Code:
UPDATE `mybb_users` SET `birthday` = '' WHERE `birthday` LIKE '-%';

Members falsely show as visited post merge
Code:
UPDATE mybb_users SET lastvisit = UNIX_TIMESTAMP(NOW()) where lastvisit = '';
UPDATE mybb_users SET lastactive = UNIX_TIMESTAMP(NOW()) where lastactive = '';

Cannot Send Mass Mail to all users post merge
Code:
UPDATE `mybb_users` SET `allownotices` = '1';

CodeWeavers - CrossOver: Windows Compatibility on Macintosh and Linux
[Image: Advocate_125.png]
Doesn't like unsolicited PMs
Find all posts by this user
Thread Closed 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)

Contact Us | MyBB | Return to Top | Return to Content | Lite (Archive) Mode | RSS Syndication