A safe way to upgrade table definitions by using ALTER's

Поиск
Список
Период
Сортировка
От Sergey Samokhin
Тема A safe way to upgrade table definitions by using ALTER's
Дата
Msg-id e42595410908271342g53c7350fva922794827e079a3@mail.gmail.com
обсуждение исходный текст
Ответы Re: A safe way to upgrade table definitions by using ALTER's
Re: A safe way to upgrade table definitions by using ALTER's
Список pgsql-general
Hello.

As I know upgrading database structure from one version to another is
usually done by applying some sql-script with a set of ALTER's that do
all the work.

But how do programmers guarantee that ALTER's they have wrote will
always be applied by administrators to the corresponding version of
the database?

Is there a standard way to store some kind of metainformation in DB
(like version of the current definitions of tables) and then check if
it is too old for being upgraded by a given script?

By "database structure" I mean definition of tables an application
uses (data types, constraints, modificators etc), stored procedures
etc.

Thanks.

--
Sergey Samokhin

P.S. If there is other convinient way to do upgrades which I've missed
- please let me know. I'm still a novice in the PostgreSQL/SQL world.

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: query that worked in 8.1 not working in 8.4
Следующее
От: Sean Foreman
Дата:
Сообщение: Re: query that worked in 8.1 not working in 8.4