Re: List Functions and Code

From: David Johnston <polobo(at)yahoo(dot)com>
To: Rebecca Clarke <rebecca(at)clarke(dot)net(dot)nz>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: List Functions and Code
Date: 2011-07-29 02:07:05
Message-ID: D8A2DE13-8B94-488F-9F34-39CFC821B91F@yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I'm pretty sure there is a way to get the source from either the schema or catalog, but I do not know what it is. However, if you are dealing with a one-time need you could always just pg_dump the schema as text and search through it using regex/grep tools (or even just "find")

David J

On Jul 28, 2011, at 9:31, Rebecca Clarke <rebecca(at)clarke(dot)net(dot)nz> wrote:

> Hi
>
> I want to search and list all the functions in a database that reference a particular table within its code. Is there a way to do this?
>
> I can list all the functions from pg_proc, however there is nothing there which provides the code of the function, so therefore I can't query if it mentions a table. I've tried looking in information_schema.routines but this unfortunately does not have it either.
>
> Rebecca
>
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Adrian Klaver 2011-07-29 02:20:47 Re: I'm in the depths of a CAST nightmare and I can't work my out
Previous Message Tom Lane 2011-07-28 23:52:31 Re: using xmin in a query?