Hi,
Steffan A. Cline wrote:
I am trying to set up a forum where there are main posts with replies and
replies to replies. Rather than using nested queries in my middleware I am
thinking there has to be some kind of recursive query where I can output the
results in a format like so:
MAIN
On 7/8/07, Steffan A. Cline [EMAIL PROTECTED] wrote:
I am trying to set up a forum where there are main posts with replies and
replies to replies. Rather than using nested queries in my middleware I am
thinking there has to be some kind of recursive query where I can output
the
results in a
I am trying to set up a forum where there are main posts with replies and
replies to replies. Rather than using nested queries in my middleware I am
thinking there has to be some kind of recursive query where I can output the
results in a format like so:
MAIN
Reply to main
reply to
this, but just wondered if there are any
functions in MySQL that make this easier, or specific functions
available to stored procedures. I have read the manual and couldn't find
anything, but thought I would ask.
I notice that the new MS SQL Server has support for recursive queries
and couldn't find
anything, but thought I would ask.
I notice that the new MS SQL Server has support for recursive queries
and oracle also, so I thought maybe...
Thanks
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:http
Title: DIY MTB
Is there any built in or other
support for recursive queries . I suspect not, but wonder what is
considered the best approach.
With stored procedures being supported in 5.0 is that the way to handle
these.
Thanks
--
Duncan Miller
[EMAIL PROTECTED]
www.diymtb.com.au
Duncan Miller [EMAIL PROTECTED] wrote on 12/08/2005 06:40:55 AM:
Is there any built in or other support for recursive queries . I
suspect not, but wonder what is considered the best approach.
With stored procedures being supported in 5.0 is that the way to handle
these.
Thanks
anything, but thought I would ask.
I notice that the new MS SQL Server has support for recursive queries
and oracle also, so I thought maybe...
Thanks
I have a table that represents a tree structure via a self-join. I'd
like to get hold of all parent records in a single query - is such a
thing possible? e.g. given
idparentid
10
21
32
42
51
64
If I was starting with record 4, I would want it to return records 2
Hi,
in oracle we have connect by prior for hierachical data traversal.
in mysql, you can use group_concat like this :
mysql select parentid, group_concat(id) from ids
- group by parentid;
+--+--+
| parentid | group_concat(id) |
+--+--+
|
On 13 May 2005, at 10:02, [EMAIL PROTECTED] wrote:
if you use php, you can look at
http://www.sitepoint.com/article/hierarchical-data-database
That's just what i needed, great article. Thanks,
Marcus
--
Marcus Bointon
Synchromedia Limited: Putting you in the picture
[EMAIL PROTECTED] |
Am Freitag, 13. Mai 2005 10.32 schrieb Marcus Bointon:
I have a table that represents a tree structure via a self-join. I'd
like to get hold of all parent records in a single query - is such a
thing possible? e.g. given
idparentid
10
21
32
42
51
64
There is
Quick searches of Google and the MySQL page didn't turn up anything, so I'll ask here..
Here's what I have:
I have a table that among others, have fields called 'section_id' and 'parent_id'. The
section_id is the id of the "self" section, and the parent_id is the id of the section
that "owns"
Equipment, to Golf to Golf
Equipment..
hope this helps..
-
Johnny Withers
[EMAIL PROTECTED]
p. 601.853.0211
c. 601.954.9133
-Original Message-
From: Isaac Force [mailto:[EMAIL PROTECTED]]
Sent: Sunday, March 04, 2001 5:03 PM
To: [EMAIL PROTECTED]
Subject: Recursive
create table root(
create table subcats(
create table subsections(
And now I need 230 levels, huh :).
How about a simple tree structure ?
hth
pa
-
Before posting, please check:
http://www.mysql.com/manual.php (the
On Mon, 5 Mar 2001 10:13:29 -0600
"Johnny Withers" [EMAIL PROTECTED] wrote:
Well, if you have everything setup right.. this is easy to do in SQL.
Lets say you have your root table:
[...]
and your sub categories:
[...]
and your final category:
[...]
now you can simply join all
On Mon, 5 Mar 2001 21:50:42 +
Pierre-Alain Joye [EMAIL PROTECTED] wrote:
create table root(
create table subcats(
create table subsections(
And now I need 230 levels, huh :).
How about a simple tree structure ?
If our thinking of a tree structure is the same, I believe that this
Quick searches of Google and the MySQL page didn't turn up anything,
so I'll ask here..
Here's what I have:
I have a table that among others, have fields called 'section_id'
and 'parent_id'. The section_id is the id of the "self" section, and
the parent_id is the id of the section that "owns"
18 matches
Mail list logo