Received: from mail.urz.uni-wuppertal.de (mail.urz.uni-wuppertal.de [132.195.64.1]) by postgresql.org (Postfix) with ESMTP id E0A73475909; Mon, 11 Mar 2002 03:30:20 -0500 (EST) Received: from fitschi.urz.uni-wuppertal.de (fitschi.urz.uni-wuppertal.de [132.195.64.7]) by mail.urz.uni-wuppertal.de (8.9.3/8.9.3) with ESMTP id JAA99776468; Mon, 11 Mar 2002 09:30:19 +0100 (MET) Received: from localhost ([127.0.0.1] helo=uni-wuppertal.de) by fitschi.urz.uni-wuppertal.de with esmtp (Exim 3.34 #1 (Debian)) id 16kLCE-0000z9-00; Mon, 11 Mar 2002 09:30:19 +0100 Message-ID: <3C8C6B1A.3E690D3D@uni-wuppertal.de> Date: Mon, 11 Mar 2002 09:30:18 +0100 From: karin probost X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.4.6 i686) X-Accept-Language: en MIME-Version: 1.0 To: HACKERS , SQL Subject: Operator ~ on type aclitem in pgsql 7.2 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Archive-Number: 200203/109 X-Sequence-Number: 6990 Iam testing postgresql 7.2 In postgres 6.5 i used the ~ Operator on type aclitem to search: has user xyz the permisssion x on table x ? This is useful to disable update-buttons in the GUI for users who have only read-permissions. with the following command as example select relname , relacl from pg_class where relacl ~ 'nobody=r'::aclitem and relname = 'tab1' ; In 7.2 this command only is successful if r is the only permission of nobody on the table. To show the effect the following commands: relname | relacl ---------+------------------------------------ tab1 | {=,probost=arwdRxt,nobody=r} tab2 | {=,probost=arwdRxt,nobody=arwdRxt} tab3 | {=,probost=arwdRxt,nobody=r} (3 rows) select relname , relacl from pg_class where relkind ='r' and relname !~ '^pg_' relname | relacl ---------+------------------------------ tab1 | {=,probost=arwdRxt,nobody=r} tab3 | {=,probost=arwdRxt,nobody=r} (2 rows) select relname , relacl from pg_class where relacl ~ 'nobody=r'::aclitem ; May I change the syntax of the sql ? is this an error ? is there another possibility to reply to the above question ? -- MfG ------------------------------------------------------------------------- - Karin Probost - Bergische Universitaet Wuppertal - RECHENZENTRUM Raum P-.09.05 - Gaussstr. 20 - D-42097 Wuppertal - Germany - - Tel. : +49 -202 /439 3151 ,Fax -2910 --Email: probost@uni-wuppertal.de --Home : http://www.hrz.uni-wuppertal.de/hrz/personen/k_probost.html -------------------------------------------------------------------------