[thesite] sequence of articles on front page

jeff jeff at members.evolt.org
Thu Dec 21 19:08:32 CST 2000


rudy,

:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
: From: rudy
:
: how is it that pintsize's and sgd's birthday articles
: slipped down below dan's (which was the first)?
: roll your mouse over the links and see the article
: numbers
:
: does the home page ORDER BY use date only?  it
: should be datetime, n'est-ce pas?  or, if that's not
: possible, then date plus article number....
:~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

here's the query from the article listing template:

SELECT
    content.contentid,
    content.contentname,
    content.synopsis,
    content.datemod,
  	content.replies,
    users.userid,
    users.who,
    categorys.category,
    categorys.categoryid,
    (SELECT Count(*)
     FROM replies
     WHERE contentid = content.contentid
          AND datemod > '21-Dec-00') AS newcomments
  FROM
    content,
    users,
    categorys
  WHERE content.signoff = 1
       AND content.userid = users.userid
       AND content.categoryid <> 23
       AND content.categoryid <> 26
       AND content.categoryid = categorys.categoryid
  ORDER BY content.datemod DESC

apparently oracle isn't paying attention to timestamps.  maybe we can force
it using datepart() or something.  the other idea of adding an additional
column to order by (contentid DESC) is a good idea too.  i'm not able to
connect to the server to edit the files right now, but when i get a chance
i'll make those changes.

thanks,

.jeff

name://jeff.howden
game://web.development
http://www.evolt.org/
mailto:jeff at members.evolt.org





More information about the thesite mailing list