How to display (metrics) databases size within one Azure postgres flexible server.

Vasek Polak 80 Reputation points
2023-10-11T13:39:08.71+00:00

There is a metric that displays the size of individual databases in Azure postgres flexible server?

Azure Database for PostgreSQL
{count} votes

Accepted answer
  1. ShaktiSingh-MSFT 16,271 Reputation points
    2023-10-12T08:22:40.09+00:00

    Hi Vasek Polak •,

    Welcome to Microsoft Q&A forum and thanks for using Azure Services.

    As I understand, you want to get database size of all databases in Azure Flexible Server.

    You may use pg_database_size() mentioned here: https://pgpedia.info/p/pg_database_size.html

    or pg_total_relation_size() which is a function for determining the total size of a relation. https://pgpedia.info/p/pg_total_relation_size.html

    Also refer to https://stackoverflow.com/questions/41991380/whats-the-difference-between-pg-table-size-pg-relation-size-pg-total-relatio Stackoverflow thread which might help.

    Please let us know if you have further queries.

    Thanks

    0 comments No comments

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.