Re: recursive search
Date: Mon, 12 Sep 2016 21:05:30 +0200
Message-ID: <1758919.oMNUckLgyt_at_PointedEars.de>
mireero wrote:
> On 09/11/2016 04:38 AM, Thomas 'PointedEars' Lahn wrote:
>> mireero wrote: >> ^^^^^^^ >> Your real name belongs there.
>
> Why ?
Civility.
> Is this a part of the "net-attitude" ?
Of the network _etiquette_ (_netiquette_), as far as I am concerned.
> I thought the signature was meant to be able to identify someone from
> one message to another.
No, the signature is optional, and its content not specified.
> Real name or pseudo, either way that do the job, no ?
No.
> FYI, I'm Michael Robertson, south of France, 38 :)
You know what you have to do now.
> Ok,I won't answer every messages, just some comments here.
Most of which are unrelated to my posting. This is thread-based communication. Learn to post.
> […]
> (you don't really have to answer that, I'll google it...) ?
Very good.
> […]
> - How can I store found results while the procedure is "recursing" to
> avoid an infinite loop ?
Look up “accumulator recursion”.
> I would need something like an array which would grow on each iteration
> and be tested against each result of the current iteration so I can get
> out of the procedure if needed (I'm clear?).
Yes. I suggest using FIND_IN_SET(), unless you want to use a (temporary inMEMORY) table with a PRIMARY KEY instead.
> - What the hell! setting max_sp_recursion_depth = 255 and being limited
> to "15!" (factorial(15)) ?
It was an *example* to show that recursion is possible in MySQL. You can increase the stack size if you need more than that.
> - If I do manage to do it the procedural way, what about performance ? I
> mean compared to adding a PHP layer ?
Try and see.
> --
> mireero
Had this been a signature, my newsreader would have removed it automatically when replying. The delimiter is wrong, it has to be “-- ” (dash, dash, *space*).
-- PointedEars Twitter: _at_PointedEars2 Please do not cc me. / Bitte keine Kopien per E-Mail.Received on Mon Sep 12 2016 - 21:05:30 CEST