This will make it easier to collect more rows.
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
our ($flight) = @ARGV;
our @cols = qw(job name val);
+our @rows;
$flight =~ m/^\d+/ or $flight = "'$flight'";
my $qfrom = "FROM runvars WHERE flight=$flight AND $synthcond";
while (my (@row) = $q->fetchrow_array()) {
my $synth = shift @row;
$row[1] .= $synthsufx if $synth && $synth ne 'f'; # sqlite3 is typeless
- printf "%-*s %-*s %-*s\n", map { $colws[$_], $row[$_] } qw(0 1 2)
+ push @rows, \@row;
+}
+
+foreach my $row (@rows) {
+ printf "%-*s %-*s %-*s\n", map { $colws[$_], $row->[$_] } qw(0 1 2)
or die $!;
}