Thank you for your advice, Jelte.
I have refactored my code, please see the attached patch. (and I put it into 
https://commitfest.postgresql.org/45/ for trace)

Thanks.

________________________________
From: Jelte Fennema <postg...@jeltef.nl>
Sent: Monday, September 11, 2023 15:04
To: Hongxu Ma <inte...@outlook.com>
Cc: David G. Johnston <david.g.johns...@gmail.com>; PostgreSQL Hackers 
<pgsql-hack...@postgresql.org>
Subject: Re: PSQL error: total cell count of XXX exceeded

On Mon, 11 Sept 2023 at 08:51, Hongxu Ma <inte...@outlook.com> wrote:
>
> I created a patch to fix it.
> Really appreciate to anyone can help to review it.
> Thanks.

I think "product" as a variable name isn't very descriptive. Let's
call it total_cells (or something similar instead).

Other than that I think it's a good change. content->cellsadded is
also a long, So I agree that I don't think the limit of int cells was
intended here.

Attachment: v2-0001-Using-long-type-in-printTableAddCell.patch
Description: v2-0001-Using-long-type-in-printTableAddCell.patch

Reply via email to