RagingPenguin
Thu 8th Jan '09, 4:33pm
So I recently set up a new installation (vb) of an old forum (discus) and it went off without a hitch. All data expected was captured. However, some things need to be updated manually and I am not that great with raw SQL. Could somebody tell me what query / queries I need to run to accomplish the following?
Using table.fields as listed:
user.userid
user.joindate
user.lastvisit
user.lastactivity
user.lastpost
user.lastpostid
post.postid
post.userid
post.dateline
Update joindate, lastvisit, lastactivity, and lastpost based on values in post. Post has accurate value in the fields above, but user does not.
Joindate should be equal to that users earliest post.dateline - 24 hous.
If they haven't posted, use ealiest overall post.dateline - 24 hours.
Lastvisit and Lastactivity should be similar, but use latest post.dateline and no time adjust.
If somebody can get me start on this, I think I can figure out the rest of what I need on my own.
Thanks in advance.
Using table.fields as listed:
user.userid
user.joindate
user.lastvisit
user.lastactivity
user.lastpost
user.lastpostid
post.postid
post.userid
post.dateline
Update joindate, lastvisit, lastactivity, and lastpost based on values in post. Post has accurate value in the fields above, but user does not.
Joindate should be equal to that users earliest post.dateline - 24 hous.
If they haven't posted, use ealiest overall post.dateline - 24 hours.
Lastvisit and Lastactivity should be similar, but use latest post.dateline and no time adjust.
If somebody can get me start on this, I think I can figure out the rest of what I need on my own.
Thanks in advance.