Re: How to check if a Procedure or FUNCTION EXIST

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Edwin UY <edwin(dot)uy(at)gmail(dot)com>
Cc: Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: How to check if a Procedure or FUNCTION EXIST
Date: 2025-05-28 00:26:51
Message-ID: CAKFQuwbahQY6iNv_80XNg3Za-9A3EExraRuL8HnGr8V9tbvvQQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Tuesday, May 27, 2025, Edwin UY <edwin(dot)uy(at)gmail(dot)com> wrote:

> Hi David J
>
> Just thought I will just have to check whether the proowner is one of the
> users/roles that we've created and if it is so, then it is not a system
> function.
> By system function, I mean something like version or current_user, they
> are system functions, right? Or am I wrong again :(
>

I mean, so long as you never use/leave “postgres” (or whatever your
bootstrap role name is) as the owner of a user-defined function it can
work. Schema just seems easier though…

David J.

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Gambhir Singh 2025-05-28 14:20:17 Replication Slots.
Previous Message Edwin UY 2025-05-28 00:22:38 Re: How to check if a Procedure or FUNCTION EXIST