I am trying to get something like the following:
Title
---------------------
topic #1
sub topic #1.1
topic #2
sub topic #2.1
sub topic #2.2
from the following table (I am using php for scripting).
forum
------------
id int
parent_id int (refers to the forum.id field)
title
...
How can I get the above output in the correct order since the posts
into the table can come in any order? I have tried various order by's
and group by's.
I am so lost on this.
Thanks in Advance,
Scott Hathaway
query, sql
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php