Re: Remove Modifiers on Table
От | Jaime Casanova |
---|---|
Тема | Re: Remove Modifiers on Table |
Дата | |
Msg-id | BANLkTin5tMc5rY637sykWm4EEk1o7CeCuA@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Remove Modifiers on Table (Carlos Mennens <carlos.mennens@gmail.com>) |
Ответы |
Re: Remove Modifiers on Table
|
Список | pgsql-general |
On Tue, May 17, 2011 at 10:14 AM, Carlos Mennens <carlos.mennens@gmail.com> wrote: > > Yes that worked perfect! I'm just curious if I have 20 tables and then > want all the 'id' columns to be auto incrementing , that means I have > to have 20 listed sequences for all 20 unique tables? yes > Seems very > cluttered and messy for PostgreSQL. Can one sequence be attributed to > multiple columns in multiple tables? you can use only one sequence for all yes... but then you will have id=1 in one table, id=2 in another, etc... i mean, it will generate one single list of values for all tables > I'm used to MySQL where this was > as easy as running: > > CREATE TABLE test ( > id INT PRIMARY KEY AUTO INCREMENT); > in postgres is as easy as CREATE TABLE test( id SERIAL PRIMARY KEY); hey! it's even less keystrokes! -- Jaime Casanova www.2ndQuadrant.com Professional PostgreSQL: Soporte y capacitación de PostgreSQL
В списке pgsql-general по дате отправления: