Search Postgresql Archives

Re: Many-to-many problem

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

 



On 18/03/2010 23:18, Grant Allen wrote:
> Hi Raymond,
> 
>> From a strictly relational viewpoint, this is as easy as
> 
> (select users.uid, apps.appcode from apps, users)
> except
> (select canaccess.uid, canaccess.appcode from canaccess)

Joe & Grant, thanks for your replies... I knew it had to be easy....
that'll teach me to finish working earlier while the brain is clear!

The cartesian product is no problem in my case, as the size of both
tables will never get any bigger than a few dozen rows each.

> It might suit you ... otherwise you'll need to go for the correlated
> subquery approach using not exists.

Can I ask for an example of this?

Thanks,

Ray.


-- 
Raymond O'Donnell :: Galway :: Ireland
rod@xxxxxx

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[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