Re: Add column and specify the column position in a table

Поиск
Список
Период
Сортировка
От Joshua D. Drake
Тема Re: Add column and specify the column position in a table
Дата
Msg-id 446B9C5C.9080401@commandprompt.com
обсуждение исходный текст
Ответ на Add column and specify the column position in a table  (Emi Lu <emilu@encs.concordia.ca>)
Список pgsql-general
Emi Lu wrote:
> Hello,
>
> I am trying to insert one column to a specific position in a table.
>
> In mysql, I can do:
> . create table test(id varchar(3), name varchar(12));
> . alter table test add column givename varchar(12) after id;
>
>
> I am looking for similar things in postgresql to add a new column to the
> correct position in a table.
>
> Could someone hint me please.

You can't. You can only add columns to the end of a table.

>
> Thanks alot!
> Ying Lu
>
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: explain analyze is your friend
>


--

    === The PostgreSQL Company: Command Prompt, Inc. ===
Sales/Support: +1.503.667.4564 || 24x7/Emergency: +1.800.492.2240
    Providing the most comprehensive  PostgreSQL solutions since 1997
              http://www.commandprompt.com/



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

Предыдущее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: FATAL: could not read statistics message
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: ALTER SEQUENCE