Re: changing multiple pk's in one update
| От | Scott Marlowe |
|---|---|
| Тема | Re: changing multiple pk's in one update |
| Дата | |
| Msg-id | dcc563d10904101120y49f00977nc74132e982518444@mail.gmail.com обсуждение исходный текст |
| Ответ на | changing multiple pk's in one update (Stuart McGraw <smcg2297@frii.com>) |
| Ответы |
Re: changing multiple pk's in one update
Re: changing multiple pk's in one update |
| Список | pgsql-sql |
2009/4/7 Stuart McGraw <smcg2297@frii.com>: > Hello all, > > I have a table with a primary key column > that contains sequential numbers. > > Sometimes I need to shift them all up or down > by a fixed amount. For example, if I have > four rows with primary keys, 2, 3, 4, 5, I > might want to shift them down by 1 by doing: > Generally speaking, when you need to do this more than once or twice in the lifetime of your data, there's something wrong with your data model.
В списке pgsql-sql по дате отправления: