Thanks for that. I didn't realise you could use the loop variable in that way. Did you really mean loop.last? or maybe loop.previous?
Thanks,
Jason
Andy Wardley wrote:
Jason Lewis wrote:
[% FOREACH item DBI.query('select Catagory, Item from Products groupby catagory')
Something like this should do it:
[% IF item.catagory != loop.last.catagory %] ... [% END %]
Any suggestions greatly appreciated.
Check the spelling of "category"? :-)
HTH
A
_______________________________________________ templates mailing list [EMAIL PROTECTED] http://lists.template-toolkit.org/mailman/listinfo/templates
