Re: Removing all users from a group - Mailing list pgsql-general

From Bruno Wolff III
Subject Re: Removing all users from a group
Date
Msg-id 20050831183934.GC14167@wolff.to
Whole thread Raw
In response to Removing all users from a group  (David Sankel <camior@gmail.com>)
List pgsql-general
On Wed, Aug 31, 2005 at 12:30:14 +0200,
  David Sankel <camior@gmail.com> wrote:
>
> DELETE FROM pg_user
> WHERE usesysid = ANY ( SELECT grolist
> FROM pg_group
> WHERE groname = 'somegroupname' )
>
> But, alas, it doesn't. Neither does any combination of IN and ANY. It seems
> to me like this should work since the same syntax works if we weren't
> talking about arrays.

In 8.1 you will be able to replace the second FROM with USING to do a join
in a DELETE. Currently you need to take advantage of the missing from
feature.

pgsql-general by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: optimum settings for dedicated box
Next
From: Frank
Date:
Subject: Re: newbie - postgresql or mysql