From a7edb84851d2238c7ec449483f5bd34e40813ccd Mon Sep 17 00:00:00 2001 From: ivan Date: Wed, 15 Feb 2012 05:17:22 +0000 Subject: [PATCH] fix 477 VI --- httemplate/search/477partVI_census.html | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/httemplate/search/477partVI_census.html b/httemplate/search/477partVI_census.html index 51baef76f..3883a1c0f 100755 --- a/httemplate/search/477partVI_census.html +++ b/httemplate/search/477partVI_census.html @@ -126,11 +126,13 @@ foreach my $row ( @row_option ) { my $count_query = 'SELECT count(*) FROM ( ('. join( ') UNION ALL (', - map { my $extra = $_->{extra_sql}; my $addl = $_->{addl_from}; - "SELECT censustract from cust_pkg $addl $extra"; - } - @sql_query - ). ') ) AS foo'; + map { my $addl_from = $_->{addl_from}; + my $extra_sql = $_->{extra_sql}; + my $order_by = $_->{order_by}; + "SELECT censustract from cust_pkg $addl_from $extra_sql $order_by"; + } + @sql_query + ). ') ) AS foo'; my $link = 'cust_pkg.cgi?'. join(';', map { my $key = $_; -- 2.11.0