Re: doc: Clarify that empty COMMENT string removes the comment
Chao Li <li.evan.chao@gmail.com>
From: Chao Li <li.evan.chao@gmail.com>
To: Fujii Masao <masao.fujii@gmail.com>
Cc: "David G. Johnston" <david.g.johnston@gmail.com>,
Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>,
PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>,
zhang_qiang81@163.com
Date: 2026-03-03T03:16:59Z
Lists: pgsql-hackers
Attachments
- v4-0001-doc-Clarify-that-empty-COMMENT-string-removes-the.patch (application/octet-stream) patch v4-0001
> On Mar 3, 2026, at 08:28, Fujii Masao <masao.fujii@gmail.com> wrote: > > On Tue, Mar 3, 2026 at 8:42 AM Chao Li <li.evan.chao@gmail.com> wrote: >> >> >> >>> On Feb 28, 2026, at 09:21, David G. Johnston <david.g.johnston@gmail.com> wrote: >>> >>> On Fri, Feb 27, 2026 at 5:12 PM Chao Li <li.evan.chao@gmail.com> wrote: >>> >>> PFA v3. > > Thanks for updating the patch! LGTM > > One more comment: the handling of empty-string comments exists in both > CreateComments() and CreateSharedComments(). For better test coverage, > how about adding also the regression test to check that COMMENT with > empty-string works as expected for shared objects such as roles? > Sure. CreateSharedComments() handles database, tablespace and role, so as you suggested, I added tests for role in v4. > From: zhangqiang <zhang_qiang81@163.com> > > Hi hackers,I have verified that using an empty string does indeed delete comments. I agree this patch content enables users to better understand how the database program handles empty strings when using the COMMENT ON command in documentation, thereby improving the user experience.I think it's a good patch. > Thanks for your review. Sounds good. PFA v4: * Add tests that use NULL and ‘’ to remove comments from a role object. Best regards -- Chao Li (Evan) HighGo Software Co., Ltd. https://www.highgo.com/
Commits
-
doc: Clarify that empty COMMENT string removes the comment.
- 7ab6ac1d7f50 14.23 landed
- 4574dd44da3c 15.18 landed
- 228addbbf2c1 16.14 landed
- ec80fab7a1fd 17.10 landed
- 47ad672a76d3 18.4 landed
- bae42a54e3df 19 (unreleased) landed
-
Hello.
- 577e21b34f86 7.1.1 cited