Re: Updating pg_attribute to change field's data type from integer to bigint on very large table
В списке pgsql-general по дате отправления:
| От | Jasen Betts |
|---|---|
| Тема | Re: Updating pg_attribute to change field's data type from integer to bigint on very large table |
| Дата | |
| Msg-id | jmd4fj$jjp$1@reversiblemaps.ath.cx обсуждение исходный текст |
| Ответ на | Updating pg_attribute to change field's data type from integer to bigint on very large table (Jeff Adams <jeff.adams@noaa.gov>) |
| Список | pgsql-general |
On 2012-04-13, Jeff Adams <jeff.adams@noaa.gov> wrote: > --e89a8ff1c1e8d37deb04bd922a84 > Content-Type: text/plain; charset=ISO-8859-1 > > Thanks for the ideas Steve. I am actually working with a partitioned table > and the field I am modifying is the id field (I have reached the cap on the > integer data type and need to modify it to bigint - very poor planning on > my part!), but no related tables exist. The id field in the partitioned > tables is inherited, so I figured I needed to alter the column in the > parent table. Does this information point towards an optimal solution? > Thanks again... you can drop the inheritance and alter the tables one at a time, I did this on a partitioned table with only millions of rows when I saw what direction it was going in. As my data was partitioned by time the system had to run without some of the older data for a while while my script altered and re-inherited each partition. -- ⚂⚃ 100% natural
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера