[ic] Query iteration

Jean-Pierre Parent parentjp@videotron.ca
Thu, 29 Mar 2001 00:14:00 -0500


Hi,

I've been reading the doc and cant find a complete example on how to do a
custom query and iterate over the returned records. Does one need use
[mvasp][/mvasp] surrounded code in order to loop through a [query][/query]'s
returned values? I have this done using [query arrayref="myArray"] and then
using $Tmp->{myArray} to fetch the ref inside [mvasp][/mvasp]...but i was
wondering if there is a simpler way to do it? I cant avoid using [query]
since I'm using pattern matching operator with MySQL.

I just need the structure with a few hints on which commands would do the
trick and I'll read in the doc...

Something like:

[query sql="..."][/query]
[loop ???]
My HTML here...along with [item ???]
[/loop]

would be perfect...

Thanks.

Jean-Pierre Parent