X-Git-Url: https://code.th-h.de/?p=usenet%2Fnewsstats.git;a=blobdiff_plain;f=groupstats.pl;h=067cffc689386ec756d40f90bb283f2dc3b1fc11;hp=a6e54ba1e28d3ca1fb7298bf55d199ef83c9ccd1;hb=38fa44f89b2f0a5dac65ef1b152aefebd5513c78;hpb=7c83a673e654c823fe04d7731fd02f9bc5787703 diff --git a/groupstats.pl b/groupstats.pl index a6e54ba..067cffc 100755 --- a/groupstats.pl +++ b/groupstats.pl @@ -160,9 +160,10 @@ if ($OptReportType and $OptReportType ne 'default') { ### get length of longest newsgroup name delivered by query ### for formatting purposes my $Field = ($GroupBy eq 'month') ? 'newsgroup' : 'month'; -my $MaxLength = &GetMaxLength($DBHandle,$Conf{'DBTableGrps'}, - $Field,$SQLWhereClause,$SQLHavingClause, - @SQLBindNewsgroups); +my ($MaxLength,$MaxValLength) = &GetMaxLength($DBHandle,$Conf{'DBTableGrps'}, + $Field,'postings',$SQLWhereClause, + $SQLHavingClause, + @SQLBindNewsgroups); ### build and execute SQL query my ($DBQuery); @@ -247,7 +248,7 @@ if ($OptCaptions && $OptComments) { # output data &OutputData($OptFormat,$OptComments,$GroupBy,$Precision, $OptCheckgroupsFile ? $ValidGroups : '', - $OptFileTemplate,$DBQuery,$MaxLength); + $OptFileTemplate,$DBQuery,$MaxLength,$MaxValLength); ### close handles $DBHandle->disconnect;