From: Ian Jackson Date: Sat, 22 Aug 2009 14:45:57 +0000 (+0100) Subject: Put data into flows X-Git-Tag: 3.4~146 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~yarrgweb/git?p=ypp-sc-tools.db-test.git;a=commitdiff_plain;h=6c00612168df1037c0d58845bd99c9890f51c6d6 Put data into flows --- diff --git a/yarrg/web/routetrade b/yarrg/web/routetrade index 35bec07..de9e73c 100644 --- a/yarrg/web/routetrade +++ b/yarrg/web/routetrade @@ -107,8 +107,10 @@ my $stmt= " my $sth= $dbh->prepare($stmt); $sth->execute(@query_params); +my @flows; + % if ($qa->{'debug'}) {
 <% $stmt |h %>
@@ -116,7 +118,17 @@ $sth->execute(@query_params);
 
% } -<& dumpqueryresults, sth =>$sth &> +<& dumpqueryresults:start, sth => $sth &> +% my $flow; +% while ($flow= $sth->fetchrow_hashref()) { +% push @flows, $flow; +<& dumpqueryresults:row, sth => $sth, row => $flow &> +% } +<& dumpqueryresults:end &> + +<%perl> + + <%init> use CommodsWeb;