[ic] [query] in a [loop]
Jonathan Clark
interchange-users@icdevgroup.org
Tue May 6 07:45:01 2003
> > > Hello,
> > >
> > > Did someone tried something like this ?
> > >
> > [loop prefix=fichiers arg="a01b02c01 a01b02c02 a01b02c03"]
> > [set foo][fichiers-code][/set]
> > [query
> > type=list
> > ml=1000
> > sql="select actual_status from [scratch foo] where
> > posted_by = '[data session username]'
> > and
> > initial_status = 'confirmee'
> > "]
> >
> > > It seems not possible to execute a [query] in a [loop].
> > > Any idea ??
> >
> > Try with a scratch...
> >
> > Rene
>
>
> It seems the problem come from the [query] inside the [loop].
> I tried to set a [scratch] value, but it's the same.
Firstly, I think it should be:
[loop prefix=fichiers list="a01b02c01 a01b02c02 a01b02c03"]
Secondly, [set] does not interpolate. Since you are only using the scratch
in the page, I suggest you use [tmp]:
[loop prefix=fichiers list="a01b02c01 a01b02c02 a01b02c03"]
[tmp foo][fichiers-code][/tmp]
[query
type=list
ml=1000
sql="select actual_status from [scratch foo] where
posted_by = '[data session username]'
and
initial_status = 'confirmee'
"]
Jonathan
www.webmaint.net