> From: [email protected] [mailto:pgsql-general-
> [email protected]] On Behalf Of Clark Slater
> Sent: Tuesday, July 14, 2009 10:04 AM
> Subject: [GENERAL] filter duplicates by priority
Maybe I'm missing something, but why not something like (incoming
pseudo-SQL):
Select part_number, max(priority)
From (
Select part_number, priority from TableAndCriteria
Union all
Select part_number, priority from TableAndCriteria
Union all
Select part_number, priority from TableAndCriteria
) as allTables
Group by part_number
Matthew Hartman
Programmer/Analyst
Information Management, ICP
Kingston General Hospital
.now.
--
Sent via pgsql-general mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general