summaryrefslogtreecommitdiff
path: root/gentoobrowse/views/newebuilds.xml
blob: 1f0c5f435c2cd5a5c0f80bbefd352cde9a896cc5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
<?xml version="1.0"?>
<block xmlns:project2="http://project2.randomdan.homeip.net" xmlns:xi="http://www.w3.org/2001/XInclude">
	<xi:include href="../datasources/postgres.xml" />
	<project2:sqlview name="newebuilds" recordname="ebuild" datasource="postgres">
		<sql>
			SELECT filename, description, moddate, p.name AS pkgname, c.name AS catname,
				EXTRACT('day' FROM (SELECT MAX(fm.firstseen) FROM files fm)) - EXTRACT('day' FROM f.firstseen) AS age
			FROM ebuilds e, files f, packages p, categories c
			WHERE e.ebuildid = f.fileid
			AND e.packageid = p.packageid
			AND p.categoryid = c.categoryid
			AND f.firstseen &gt; (SELECT MAX(fm.firstseen) - INTERVAL '2.1 days' FROM files fm)
			ORDER BY c.name, p.name, e.versioninst
		</sql>
	</project2:sqlview>
</block>