Re: Add has_large_object_privilege function

Fujii Masao <masao.fujii@oss.nttdata.com>

From: Fujii Masao <masao.fujii@oss.nttdata.com>
To: Yugo NAGATA <nagata@sraoss.co.jp>
Cc: pgsql-hackers@lists.postgresql.org
Date: 2024-09-12T10:07:22Z
Lists: pgsql-hackers

On 2024/09/10 17:45, Yugo NAGATA wrote:
> On Mon, 9 Sep 2024 22:59:34 +0900
> Fujii Masao <masao.fujii@oss.nttdata.com> wrote:
> 
>>
>>
>> On 2024/07/02 16:34, Yugo NAGATA wrote:
>>> So, I would like to propose to add
>>> has_large_object_function for checking if a user has the privilege on a large
>>> object.
>>
>> +1
> 
> Thank you for your looking into this!
> I've attached a updated patch.

Thanks for updating the patches! LGTM, except for a couple of minor things:

+okui chiba * has_largeobject_privilege_id

"okui chiba" seems to be a garbage text accidentally added.

+ *		role by Oid, large object by id, and privileges as AclMode.

"Oid" seems better than "id" in "large object by id".

Regards,

-- 
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION




Commits

  1. Fix catalog data of new LO privilege functions

  2. Add has_largeobject_privilege function.

  3. Deduplicate code in LargeObjectExists and myLargeObjectExists.