[Collab-qa-commits] r950 - in udd: . web web/cgi-bin

neronus-guest at alioth.debian.org neronus-guest at alioth.debian.org
Mon Jul 28 12:41:58 UTC 2008


Author: neronus-guest
Date: 2008-07-28 12:41:58 +0000 (Mon, 28 Jul 2008)
New Revision: 950

Added:
   udd/web/
   udd/web/cgi-bin/
   udd/web/cgi-bin/packages_in_unstable_but_not_in_testing_by_popcon.cgi
   udd/web/cgi-bin/sources_in_unstable_but_not_in_testing_by_popcon_max.cgi
   udd/web/index.html
Log:
Added web folder to svn


Added: udd/web/cgi-bin/packages_in_unstable_but_not_in_testing_by_popcon.cgi
===================================================================
--- udd/web/cgi-bin/packages_in_unstable_but_not_in_testing_by_popcon.cgi	                        (rev 0)
+++ udd/web/cgi-bin/packages_in_unstable_but_not_in_testing_by_popcon.cgi	2008-07-28 12:41:58 UTC (rev 950)
@@ -0,0 +1,31 @@
+#!/usr/bin/perl -T
+
+use strict;
+use warnings;
+
+use DBI;
+use CGI;
+
+my $dbh = DBI->connect("dbi:Pg:dbname=udd") or die $!;
+my $sth = $dbh->prepare(<<EOF
+	SELECT DISTINCT unstable.package, (vote + olde + recent + nofiles) as pvote
+        FROM (SELECT DISTINCT package FROM packages
+                WHERE distribution = 'debian' and release = 'sid')
+          AS unstable,
+             popcon
+        WHERE NOT EXISTS (SELECT * FROM packages where distribution = 'debian'
+                          AND release = 'lenny' and package = unstable.package)
+              AND popcon.name = unstable.package AND popcon.distribution = 'debian' ORDER BY pvote DESC;
+EOF
+	);
+
+$sth->execute() or die $!;
+
+my $q = CGI->new();
+
+print $q->header(-type => 'text/plain');
+while(my @row = $sth->fetchrow_array) {
+	my ($package, $score) = @row;
+	print "$package\t$score\n";
+}
+

Added: udd/web/cgi-bin/sources_in_unstable_but_not_in_testing_by_popcon_max.cgi
===================================================================
--- udd/web/cgi-bin/sources_in_unstable_but_not_in_testing_by_popcon_max.cgi	                        (rev 0)
+++ udd/web/cgi-bin/sources_in_unstable_but_not_in_testing_by_popcon_max.cgi	2008-07-28 12:41:58 UTC (rev 950)
@@ -0,0 +1,31 @@
+#!/usr/bin/perl -T
+
+use strict;
+use warnings;
+
+use DBI;
+use CGI;
+
+my $dbh = DBI->connect("dbi:Pg:dbname=udd") or die $!;
+my $sth = $dbh->prepare(<<EOF
+	SELECT DISTINCT unstable.package, (vote + popcon_src_max.old + recent + nofiles) as pvote
+        FROM (SELECT DISTINCT package FROM sources
+                WHERE distribution = 'debian' and release = 'sid')
+          AS unstable,
+             popcon_src_max
+        WHERE NOT EXISTS (SELECT * FROM sources WHERE distribution = 'debian'
+                          AND release = 'lenny' and package = unstable.package)
+              AND popcon_src_max.package = unstable.package AND popcon_src_max.distribution = 'debian' ORDER BY pvote DESC;
+EOF
+	);
+
+$sth->execute() or die $!;
+
+my $q = CGI->new();
+
+print $q->header(-type => 'text/plain');
+while(my @row = $sth->fetchrow_array) {
+	my ($package, $score) = @row;
+	print "$package\t$score\n";
+}
+


Property changes on: udd/web/cgi-bin/sources_in_unstable_but_not_in_testing_by_popcon_max.cgi
___________________________________________________________________
Name: svn:executable
   + *

Added: udd/web/index.html
===================================================================
--- udd/web/index.html	                        (rev 0)
+++ udd/web/index.html	2008-07-28 12:41:58 UTC (rev 950)
@@ -0,0 +1,20 @@
+<html>
+  <title>
+    The Ultimate Debian Database Example Queries
+  </title>
+  <body>
+    <h1>
+      The Ultimate Debian Database (UDD) example queries
+    </h1>
+
+    <p>
+    To provide you with an idea what results UDD can deliver,
+    I will link some example queries from here
+    </p>
+
+    <p>
+    <a href=/cgi-bin/packages_in_unstable_but_not_in_testing_by_popcon.cgi>
+      Packages in unstable, but not in testing, sorted by popcon
+    </a>
+  </body>
+</html>




More information about the Collab-qa-commits mailing list