Re: pg_get_databasebyid(oid) - Mailing list pgsql-hackers

From Sergei Kornilov
Subject Re: pg_get_databasebyid(oid)
Date
Msg-id 51165371567073785@myt5-b646bde4b8f3.qloud-c.yandex.net
Whole thread Raw
In response to Re: pg_get_databasebyid(oid)  (Ibrar Ahmed <ibrar.ahmad@gmail.com>)
Responses Re: pg_get_databasebyid(oid)  (Ibrar Ahmed <ibrar.ahmad@gmail.com>)
List pgsql-hackers
Hello

> Is there a need for this function for the user?

This was feature request from user. I got such comment:

This function is useful when working with pg_stat_statements. For obtaining a databаse name for particular query you
needto join pg_database relation, but for obtaining an username you just need pg_get_userbyid(). So it will be useful
notto join extra relation and get a database name using the similar function - pg_get_databasebyid().
 

regards, Sergei



pgsql-hackers by date:

Previous
From: Jeevan Ladhe
Date:
Subject: Re: basebackup.c's sendFile() ignores read errors
Next
From: Ibrar Ahmed
Date:
Subject: Re: pg_get_databasebyid(oid)