The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
SQL Query - Change Last Activity Date
My forum was imported from another system. All user that have NOT logged in since the change over have a last activity date that is blank. In addition the "Receive Admin Emails" is unchecked.
I would like to run a couple of query's. One: If the last activity is blank THEN set receive admin emails to YES Two: Set last activity to a date so it isn't blank. I am using a plugin that sends reminder emails to in inactive users and they are being left out because of the no date issue. Can anyone help? Thanks! |
#2
|
|||
|
|||
Try this:
Code:
UPDATE user SET options = options + 16 WHERE lastactivity = 0 AND NOT (options & 16) and Code:
UPDATE user SET lastactivity=UNIX_TIMESTAMP('2012-01-01 15:30:00') WHERE lastactivity = 0 Of course you can set the date and time to whatever you want. |
#3
|
||||
|
||||
That worked perfectly. Thank You!!
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|