The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Would like help/advice on SQL query...
I'm throwing together a little statistics page (www.online-roleplaying.com/forums/statistics.php) and asked a few of my members what sort of statistics they would like.
Surprisingly, the one with the most posts per day, suggested a list of people with the highest posts per day values. It's a good idea, but after having taken a look through the vbulletin files (to figure out how Jelsoft calculated it), I got the impression it's pretty difficult to create a list of users sorted by this condition. Anyone of you guys got ideas? |
#2
|
||||
|
||||
Hmm i've tried something like that:
SELECT username, (posts / (". time()."-signupdate)/3600*24) AS postsperday FROM user ORDER By postsperday it has ordered in some way but i didn't found out how ^^ |
#3
|
||||
|
||||
*marvels at Xenon's intellect*
Replace signupdate with joindate and it DOES sort them properly. Now somehow using $user[postsperday] is set to 0.0000 I bet I'm overlooking something, so feel free to point it out to me |
#4
|
||||
|
||||
yeah, meant joindate, but there i also have had some problems
|
#5
|
||||
|
||||
What a big difference 1 pair of ()'s makes... *blushes*
|
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|