Re: Does has_table_privilege() have a case bug - Mailing list pgsql-general

From Jeff Davis
Subject Re: Does has_table_privilege() have a case bug
Date
Msg-id 1202257639.24634.73.camel@dogma.ljc.laika.com
Whole thread Raw
In response to Does has_table_privilege() have a case bug  (johnf <jfabiani@yolo.com>)
Responses Re: Does has_table_privilege() have a case bug
List pgsql-general
On Tue, 2008-02-05 at 16:10 -0800, johnf wrote:
> I create a table named "Account_Text_Table" the owner is 'johnf'.
>
> select has_table_privilege('johnf', 'public.Account_Text_Table', 'SELECT')
> I get the following error:
>
> ERROR:  relation "public.account_text_table" does not exist

PostgreSQL folds to lower case unless you put the name in double-quotes.
Try putting the table name in double-quotes.

E.g.: select has_table_privilege('johnf', 'public."Account_Text_Table"',
'SELECT')

Regards,
    Jeff Davis


pgsql-general by date:

Previous
From: johnf
Date:
Subject: Does has_table_privilege() have a case bug
Next
From: brian
Date:
Subject: Re: Does has_table_privilege() have a case bug