The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Quick SQL question
[sql]
SELECT t.threadid, t.title, t.firstpostid, t.lastpost, t.replycount, t.postusername, t.postuserid, t.lastposter, t.dateline, t.views, LEFT(p.pagetext,120) as pagetext FROM " . TABLE_PREFIX . "thread t LEFT JOIN " . TABLE_PREFIX . "post p ON p.postid = t.firstpostid WHERE t.forumid = '151' AND t.open = '1' AND t.visible = '1' ORDER BY t.dateline DESC LIMIT 0 , 17 [/sql] Could someone please edit this so it only grabs threads posted that day. And also one that would grab 17 of the next newest threads, not including those posted that day if possible? Thanks |
#2
|
|||
|
|||
[sql]
SELECT t.threadid, t.title, t.firstpostid, t.lastpost, t.replycount, t.postusername, t.postuserid, t.lastposter, t.dateline, t.views, LEFT(p.pagetext,120) as pagetext FROM " . TABLE_PREFIX . "thread t LEFT JOIN " . TABLE_PREFIX . "post p ON p.postid = t.firstpostid WHERE t.forumid = '151' AND t.open = '1' AND t.visible = '1' AND t.dateline >= TIMENOW - 86400 ORDER BY t.dateline DESC LIMIT 0 , 17 [/sql] |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|