RE: [GENERAL] Re: More PostgreSQL stuff

Поиск
Список
Период
Сортировка
От Jackson, DeJuan
Тема RE: [GENERAL] Re: More PostgreSQL stuff
Дата
Msg-id F10BB1FAF801D111829B0060971D839F447DFD@cpsmail
обсуждение исходный текст
Ответы Re: [GENERAL] Re: More PostgreSQL stuff  (Martin Schulze <joey@finlandia.Infodrom.North.DE>)
Список pgsql-general
> Martin Schulze wrote:
>   >Hi Oliver!
>   >
>   >I have some more questions wrt. PostgreSQL.
>
> Forwarded to PostgreSQL list, since I cannot answer them.
>
>   > . Why does pg_dump only write some SQL commands in capital letters
>   >   but not all?  I wonder if that's intentional.  Please look at
> the
>   >   following excerpt.  I would have expected CHAR, VARCHAR, INSERT
>   >   INTO, VALUES etc. to occur in capital letters.
>   >
>   >   CREATE TABLE zeitungen (name char(30), typ char(10), ...
>   >
>   >   insert into zeitungen values ('Mallorca Immobilien
> ',...
CAPS/no-CAPS are just a preference of the coder's of pg_dump.  If you
want you can go through the source of pg_dump and uppercase all the SQL
and recompile.

>   >
>   > . I wonder how one could add or remove columns from existing
> tables.
>   >
>   >   With mSQL this was possible with a trick.  You had to dump the
>   >   whole table but you could tell the dump program to add dummy
> fields
>   >   or to leave out existing fields.  Is there any such possibility
>   >   with PostgreSQL?
You can do a select into a temp table with the added columns, drop the
old table the rename the temp table to the old name.  You'll also have
to recreate your indexes, triggers, and rules.
        -DEJ

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

Предыдущее
От: Martin Schulze
Дата:
Сообщение: Re: More PostgreSQL stuff
Следующее
От: Martin Schulze
Дата:
Сообщение: Re: [GENERAL] Re: More PostgreSQL stuff