Search Postgresql Archives

Re: Select question..... is there a way to do this?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Aug 3, 11:17 pm, k...@xxxxxxxxxxxxx (Karl Denninger) wrote:
> Ideas?

SELECT item.user, item.subject, item.number
  FROM item, seen
 WHERE item.user = seen.user
   AND item.number = seen.number
   AND item.changed > seen.lastviewed
UNION
SELECT item.user, item.subject, item.number
  FROM item, seen
 WHERE item.user = seen.user
   AND seen.number IS NULL
   AND item.changed > seen.lastviewed;


---------------------------(end of broadcast)---------------------------
TIP 5: don't forget to increase your free space map settings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux