]> ruin.nu Git - ndwebbie.git/blobdiff - lib/NDWeb/Include.pm
Replaced intelquery function with a view
[ndwebbie.git] / lib / NDWeb / Include.pm
index 1cbcca9de3e09790280105192f16df6345ab1f2d..e619a228d7506402b232975eebf5ac6155d7f58c 100644 (file)
@@ -27,7 +27,7 @@ use CGI qw/:standard/;
 our @ISA = qw/Exporter/;
 
 our @EXPORT = qw/parseMarkup
-       intelquery html_escape
+       html_escape
        comma_value array_expand/;
 
 sub html_escape($) {
@@ -76,18 +76,6 @@ sub parseMarkup ($) {
        return $text;
 }
 
-sub intelquery {
-       my ($columns,$where) = @_;
-       return qq{
-SELECT $columns, i.mission, i.tick AS landingtick,MIN(i.eta) AS eta, i.amount, i.ingal, u.username
-FROM (intel i NATURAL JOIN users u)
-       JOIN current_planet_stats t ON i.target = t.pid
-       JOIN current_planet_stats o ON i.sender = o.pid
-WHERE $where
-GROUP BY i.tick,i.mission,t.x,t.y,t.z,o.x,o.y,o.z,i.amount,i.ingal,u.username,t.alliance,o.alliance,t.nick,o.nick,i.sender,i.target
-ORDER BY i.tick DESC, i.mission};
-}
-
 sub array_expand ($) {
        my ($array) = @_;