| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Function to Table reference |
| Date: | 2010-04-30 16:43:58 |
| Message-ID: | 26814.1272645838@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Tim Landscheidt <tim(at)tim-landscheidt(dot)de> writes:
> (anonymous) wrote:
>> Is there a way to find which functions are being used by table.
>> Ex :- If there are functions fnc_a, fnc_b, fnc_c and table A is used in
>> fnc_a and fnc_c, How can we find that ? can you please help?
> Basically, you can't. Functions are more or less black boxes
> to PostgreSQL.
You could possibly grep all the functions' source code for references to
the particular table you care about, eg
select ... from pg_proc where prosrc ~ 'mytable'
but bear in mind that this could miss dynamically-constructed queries.
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Greg Sabino Mullane | 2010-04-30 16:46:37 | Re: savepoints with the same name |
| Previous Message | Grzegorz Jaśkiewicz | 2010-04-30 16:36:41 | information_schema.parameters |