Teasing a type definition from system tables

Teasing a type definition from system tables

Post by Don » Thu, 02 Feb 2012 00:43:03



Hi,

For "non-standard" types (e.g., composite, user-defined), is there
any way of teasing the definition out of the system catalog?

E.g.,

CREATE TYPE foo AS (
   control1 point,
   control2 point,
   dest point
);

CREATE TYPE bar AS (
   purpose text,
   action foo,
   when date
);

It seems like type definitions fall into a black hole...

Thx,
--don

 
 
 

Teasing a type definition from system tables

Post by Usernam » Fri, 03 Feb 2012 08:41:19


Hi Don,

Quote:> For "non-standard" types (e.g., composite, user-defined), is there
> any way of teasing the definition out of the system catalog?

Have a look at MogwaiERDesignerNG and its reverseengineering
capabilities: http://sourceforge.net/projects/mogwai/

The way it is done you can find in

http://mogwai.svn.sourceforge.net/viewvc/mogwai/trunk/mogwai/MogwaiER...

in the lines

194 for enumerations,
233 for composite types
312 for external types (not implemented yet)

HTH

regards

 
 
 

Teasing a type definition from system tables

Post by Jasen Bett » Sat, 04 Feb 2012 19:47:09



Quote:> Hi,

> For "non-standard" types (e.g., composite, user-defined), is there
> any way of teasing the definition out of the system catalog?

see how psql does it:

 psql -E
 \d bar

--
?? 100% natural


 
 
 

Teasing a type definition from system tables

Post by Don » Mon, 06 Feb 2012 19:18:12



Quote:> Hi Don,

>> For "non-standard" types (e.g., composite, user-defined), is there
>> any way of teasing the definition out of the system catalog?

> Have a look at MogwaiERDesignerNG and its reverseengineering
> capabilities: http://sourceforge.net/projects/mogwai/

> The way it is done you can find in
> in the lines

> 194 for enumerations,
> 233 for composite types
> 312 for external types (not implemented yet)

Excellent!  I may actually look into using the tool, itself.

Thanks!

 
 
 

Teasing a type definition from system tables

Post by Don » Thu, 09 Feb 2012 17:18:33


Hi Jasen,



>> For "non-standard" types (e.g., composite, user-defined), is there
>> any way of teasing the definition out of the system catalog?

> see how psql does it:

>   psql -E
>   \d bar

Thanks!  I'll try that next time I am logged onto the server.