Re: [DOC] pg_database_size/pg_tablespace_size error on a missing OID

Поиск
Список
Период
Сортировка
Искать

Re: [DOC] pg_database_size/pg_tablespace_size error on a missing OID

От:
Chao Li <li.evan.chao@gmail.com>
Дата:


> On Sep 5, 2026, at 21:11, shihao zhong  wrote:
> 
> Hi hackers,
> 
> The introduction to the database object size functions in
> func-admin.sgml says that passing an OID that does not represent an
> existing object returns NULL.  That is true for the relation size
> functions, but pg_database_size() and pg_tablespace_size() raise an
> error for a nonexistent OID instead.  The attached patch documents the
> exception.
> 
> Thanks,
> Shihao
> <0001-doc-note-that-pg_database_size-and-pg_tablespace_siz.patch>


The change overall looks good to me. One nitpick:
```
+    functions, NULL is returned, except by
```

“Except by” sounds uncommon, is “expect for” better?

Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/






Re: [DOC] pg_database_size/pg_tablespace_size error on a missing OID

От:
shihao zhong <zhong950419@gmail.com>
Дата:
Вложения:
Hi Chao,

Thanks for reviewing that.

> “Except by” sounds uncommon, is “expect for” better?
Updated.

Thanks,
Shihao

Re: [DOC] pg_database_size/pg_tablespace_size error on a missing OID

От:
Daniel Gustafsson <daniel@yesql.se>
Дата:
Pushed, with a few small modifications, and backpatched to v18 where the error
message was introduced.

--
Daniel Gustafsson



FAQ