Great progress today on my Reverse Engineering efforts. However; I have
some comments.

1. How can I switch databases (where I would normally use USE)?

2. How do I determine the AccessMethod specified when an index was
created?

3. It would be cool if the catalog objects had comments on them in
pg_description. Very few do.

Peter




Wed, 22 Aug 2001 22:27:23 -0700
Peter Harvey <pharvey@codebydesign.com>
Reverse Engineering
Peter Harvey wrote:
> 
> Great progress today on my Reverse Engineering efforts. However; I have
> some comments.
> 
> 1. How can I switch databases (where I would normally use USE)?

You just open another connection .

If you mean psql jou do 
\c otherdatabasename

> 2. How do I determine the AccessMethod specified when an index was
> created?

you can parse it from pg_indexes.indexdef 

A great source for reverse engineering is source of pg_dump as it has 
to do all the "reverse engineering" in order to dump everything.

> 3. It would be cool if the catalog objects had comments on them in
> pg_description. Very few do.

Yes it would :)

-------------
Hannu

Thu, 23 Aug 2001 08:59:14 +0200
Hannu Krosing <hannu@tm.ee>
Re: Reverse Engineering
Hannu Krosing <hannu@tm.ee> writes:
> Peter Harvey wrote:
>> 2. How do I determine the AccessMethod specified when an index was
>> created?

> you can parse it from pg_indexes.indexdef 

... which relies on pg_get_indexdef(index OID).

Or, look at pg_class.relam, which is zero for regular tables and a pg_am
OID for indexes.

			regards, tom lane

Thu, 23 Aug 2001 09:17:25 -0400
Tom Lane <tgl@sss.pgh.pa.us>
Re: Reverse Engineering 