diff options
-rw-r--r-- | weblog-adhocquery-html.lsp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/weblog-adhocquery-html.lsp b/weblog-adhocquery-html.lsp index d7aee5c..17ee021 100644 --- a/weblog-adhocquery-html.lsp +++ b/weblog-adhocquery-html.lsp @@ -43,20 +43,17 @@ require("viewfunctions") <% end %> <H1><%= html.html_escape(form.label) %></H1> +<% displayformstart(form, page_info) %> This form accepts a Postgresql SELECT statement and displays the results. Examples: <ul> <li>This statement will return the total bytes transferred by each user for the entire weblog history<pre>SELECT clientuserid, sum(bytes) AS total FROM pubweblog GROUP BY clientuserid ORDER BY total DESC</pre> <li>This statement limits the above statement to a specific range of dates (just yesterday)<pre>SELECT clientuserid, sum(bytes) AS total FROM pubweblog WHERE logdatetime >= 'yesterday' and logdatetime < 'today' GROUP BY clientuserid ORDER BY total DESC</pre> <li>This statement will return the number of requests and blocks by hour over the course of the entire usage history<pre>SELECT extract(hour from date) AS hour, sum(numrequest) AS numrequest, sum(numblock) AS numblock FROM usagestat GROUP BY extract(hour from date) ORDER BY hour</pre> </ul> -<% displayformstart(form, page_info) %> -<DL> <% displayformitem(form.value.query, "query") %> -</DL> <% displayformend(form) %> -<br> -The available database tables and descriptions are as follows: +<H1>The available database tables and descriptions are as follows</H1> <H3>PubWeblog and PubBlocklog</H3> <DL> These tables contain the combined squid access log and dansguardian log for every access and blocked access respectively. The definition of the table is as follows: |