Re: oid2name : add objects file path
Euler Taveira <euler@eulerto.com>
From: "Euler Taveira" <euler@eulerto.com>
To: "David Bidoc" <dcbidoc@gmail.com>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2025-10-07T09:47:28Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
oid2name: Add relation path to the information provided by -x/--extended
- 3c5ec35dea25 19 (unreleased) landed
On Tue, Oct 7, 2025, at 5:55 AM, David Bidoc wrote: > This is my first patch to the project. > Welcome to Postgres community. > I noticed that the oid2name tool does not display the file path of objects. > > I thought this could be interesting and that others might find it > useful, so I made a little patch to display the full path of objects > retrieved by the oid2name tool. These will be displayed using the -x > --extended option. > I didn't review your patch in details but I noticed 2 things that should be improved: 1. The database query is wrong because it is considering that all databases are in the default tablespace. If you create a database in a different tablespace you will notice the mistake. 2. I suggest that you change one of the examples (maybe the last one) to illustrate this feature. Since you are in this area, you could create a separate patch for show the tablespace location (-s option). Use pg_tablespace_location function. Register your patch for the next commitfest so we don't lose track of it. [1] If you don't have an account, the 'Log In' link will redirect you to the page to create a new one or even allow you to use a third party sign in. [1] https://commitfest.postgresql.org/56/ -- Euler Taveira EDB https://www.enterprisedb.com/