Re: Finding recursive dependencies
От | Tom Lane |
---|---|
Тема | Re: Finding recursive dependencies |
Дата | |
Msg-id | 19598.1294069066@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: Finding recursive dependencies (Joel Jacobson <joel@gluefinance.com>) |
Ответы |
Re: Finding recursive dependencies
|
Список | pgsql-general |
Joel Jacobson <joel@gluefinance.com> writes: > 2011/1/2 Tom Lane <tgl@sss.pgh.pa.us> >> The thing you're missing is that implicit dependencies are really >> bidirectional: > So, basically it's not possible to define a recursive query only making use > of pg_depend to build an entire dependency tree of all oids? > It appears to me it's necessary to join the object type specific tables, > such as pg_rewrite, to build a complete tree? No, that's nonsense. The information is in pg_depend; it's just not expressed in a way that makes it easy to scan it in a single recursive query. If you could do something like select base-case union all select objid ... where refobjid matches union all select refobjid ... where objid matches and deptype = 'i' then it'd be easy, but you only get one UNION ALL per recursive query. regards, tom lane
В списке pgsql-general по дате отправления: