Re: Why are tables sizes so big?

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: Why are tables sizes so big?
Дата
Msg-id 3AA5E240.FD449F78@archonet.com
обсуждение исходный текст
Ответ на Why are tables sizes so big?  (God_Of_Pain <silicontao_roy@technologist.com>)
Ответы Re: Why are tables sizes so big?
Список pgsql-general
God_Of_Pain wrote:
>
> I have a Win32 app connecting to a PostgreSQL server via Delphi -> BDE ->
> ODBC -> PostgreSQL. The app takes CSV files and stores them on the
> PostgreSQL server. An empty CSV file makes a table that is 8kB in size on
> the server and that is fine but for every 1kB of text in the CSV file the
> PostgreSQL file gains about 5kB.
>
> The CSV file has 5 text fields that I change to char size 10, float, float,
> int and float. That in it's self sould make the data on the server much
> smaller, but it is not, it is bigger, why?

char  = 10 + 4
floats= 8 * 3
int   = 4
oid   = 4

That's at least 46 bytes per row plus indexes - which can take up a lot.
Does that look plausible?

 - Richard Huxton

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

Предыдущее
От: will trillich
Дата:
Сообщение: need general optimization advice
Следующее
От: Karel Zak
Дата:
Сообщение: Re: [SQL] Re: Re: MySQLs Describe emulator!