| От | Franck Routier |
|---|---|
| Тема | Does max size of varchar influence index size |
| Дата | |
| Msg-id | 1214845078.6710.7.camel@franck-laptop обсуждение исходный текст |
| Ответы |
Re: Does max size of varchar influence index size
|
| Список | pgsql-performance |
Hi, I have problems with my database becoming huge in size (around 150 GB right now, and 2/3 for only three tables, each having around 30 millions tuples. Space is spent mainly on indices.). I have a lot of multi-column varchar primary keys (natural keys), and lot of foreign keys on these tables and thus a lot of indices. When using VARCHAR, we defaulted to VARCHAR(32) (because on _some_ of the identifiers, we have to apply md5). We assumed that using VARCHAR(32) but having values at most 4 characters long (for example) wouldn't influence indices size, ie it would be the same as using VARCHAR(4) to keep the example. Now I really doubt if we were right :) So, what should we expect ? And are there other factors influencing indices size ? Thanks, Franck
В списке pgsql-performance по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера