Re: Materialized View Estimation in Postgres

Поиск
Список
Период
Сортировка
От Thomas Kellerer
Тема Re: Materialized View Estimation in Postgres
Дата
Msg-id 57c9152b-85bf-6b9e-d1e2-8f0278882596@gmx.net
обсуждение исходный текст
Ответ на Materialized View Estimation in Postgres  (Sahul Hameed <mail2shameed@gmail.com>)
Список pgsql-admin
> I would like to know if there are any oracle equivalent of
> dbms_mview.estimate_mview_size in Postgres as we have been using it
> in Oracle for estimating required size for the upcoming mviews but
> after migration to Postgres we find it very hard to estimate the
> size.. Sometime our rds ran out of space and we had to spend lot of
> efforts and time to bring back the rds once after rds storage is
> exhausted. Or is there any other options available which can be used
> to estimate the size.

A very rough estimation could be to use pg_column_size() on the rows of your SELECT statement and aggregate that.
Despite it's name pg_column_size() also calculates the size of a complete row.

   select sum(pg_column_size(mv))
   from (
     .... your select statement here ...
   ) mv;




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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: user with autentication windows
Следующее
От: Devrim Gündüz
Дата:
Сообщение: Re: pgAdmin4 dependency package "python3-psycopg2" should be placein "pgdg-common" repo.