Data Dictionary

Поиск
Список
Период
Сортировка
От cornell mail
Тема Data Dictionary
Дата
Msg-id 200008281811.OAA03083@mailout1-1.nyroc.rr.com
обсуждение исходный текст
Список pgsql-general
Hello!

I'm new to postgresql, fairly familiar with Oracle however.

It'd be great if, in the new database I'm building, I was able to create a data
dictionary.  Essentially a table that
contains meta-data for all the other tables in the database.  Something like
this.

Already created table:
    mytable_1
    mytable_2
    yourtable_3

And the data dictionary would do something like the following:

# select * from data_dict where column_name = 'mytable_1';

table_name    column_name    data_type      nullable    data_length    etc...
----------------------------------------------------
mytable_1    mytable_col1        varchar      Y         100
etc...
mytable_1    mytable_col2         int8         Y              18
etc....
..
..



and so on.

Is there an easy way to do this in postgresql?    In oracle, all of this data is
stored in database administration
tables...are there corresponding tables in postgresql?    I'd LOVE to not have to
hand-update this table, and only
have to do something like the following:

create table data_dict as select table_name, column_name, data_type, nullable,
data_length, ... from <special
posgresql table name here>.

Any good pointers?

Saul



В списке pgsql-general по дате отправления:

Предыдущее
От: "Mike Sears"
Дата:
Сообщение: Large Objects
Следующее
От: "Martin A. Marques"
Дата:
Сообщение: developers