Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wKAqB-000geq-34 for pgsql-hackers@arkaria.postgresql.org; Tue, 05 May 2026 08:09:15 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wKAqA-00AzDW-2O for pgsql-hackers@arkaria.postgresql.org; Tue, 05 May 2026 08:09:14 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wKAqA-00AzDO-1Q for pgsql-hackers@lists.postgresql.org; Tue, 05 May 2026 08:09:14 +0000 Received: from meldrar.postgresql.org ([2a02:c0:301:0:ffff::31]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.98.2) (envelope-from ) id 1wKAq7-00000000bJZ-31Z9 for pgsql-hackers@postgresql.org; Tue, 05 May 2026 08:09:14 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=postgresql.org; s=20171124; h=Content-Transfer-Encoding:Content-Type: Mime-Version:References:In-Reply-To:From:Subject:Cc:To:Message-Id:Date:Sender :Reply-To:Content-ID:Content-Description; bh=iuXEzcUYzjfWb/fYQsugAogSPnXZ9jXteJSbM5Gt1HA=; b=fXZkGKO0pCHnt/RIoNs60hwjam 0fxt0LSAmWs2MVyWIxYkriW3kJFd8sBtNIyTRt087U8NiNSwX35EPN57G5Ltr4ZJ31jFbjqm9ZfrL +C035gdb2RNseLHQPxE3TbvSu8FgNS0VbF7Bq/k6bmK3d/TwFI1y7OWERoZ7H2DhJrjTb5mX5jt9m XIHGKQjQokdrAcT8hRxVG84AqGstQr+fIwbMIdQgOEif6ZmDkHmcteR1Di39l7UiH4n1QQudcvQ5g qIjo5SGC1j5QGTLWHkYMGn0HPj0b8kQNCOUH9NRN/C/o5x1mvuiQU1fYvDsb5jx8cIDIWXYWVqabK DT7+GZHQ==; Received: from [2409:11:4120:300:8c85:bb80:274f:1adc] (helo=localhost) by meldrar.postgresql.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wKApz-0021DG-0A; Tue, 05 May 2026 08:09:04 +0000 Date: Tue, 05 May 2026 17:08:45 +0900 (JST) Message-Id: <20260505.170845.1271951360939093763.ishii@postgresql.org> To: jian.universality@gmail.com Cc: assam258@gmail.com, zsolt.parragi@percona.com, sjjang112233@gmail.com, vik@postgresfriends.org, er@xs4all.nl, jacob.champion@enterprisedb.com, david.g.johnston@gmail.com, peter@eisentraut.org, li.evan.chao@gmail.com, pgsql-hackers@postgresql.org Subject: Re: Row pattern recognition From: Tatsuo Ishii In-Reply-To: References: <20260502.140304.670813149418899420.ishii@postgresql.org> <20260505.090124.365339750969814137.ishii@postgresql.org> X-Mailer: Mew version 6.8 on Emacs 29.3 Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Host-Lookup-Failed: Reverse DNS lookup failed for 2409:11:4120:300:8c85:bb80:274f:1adc (failed) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hi Jian, > Hi > The patchset is too big, I only downloaded v47-0001... Yeah, since the feature is complex... > 1. We need to add trailing commas to enum definitions. See > https://git.postgresql.org/cgit/postgresql.git/commit/?id=611806cd726fc92989ac918eac48fd8d684869c7 I forgot that. Thanks for reminding. > 2. > + | '{' ',' Iconst '}' Op > + { > + if (strcmp($5, "?") != 0) > + ereport(ERROR, > + (errcode(ERRCODE_SYNTAX_ERROR), > + errmsg("invalid token after range quantifier"), > + errhint("Only \"?\" is allowed after {n,} or {,m} to make it reluctant."), > + parser_errposition(@5))); > + if ($3 <= 0 || $3 >= INT_MAX) > + ereport(ERROR, > + errcode(ERRCODE_SYNTAX_ERROR), > + errmsg("quantifier bound must be between 1 and %d", INT_MAX - 1), > + parser_errposition(@3)); > + $$ = (Node *) makeRPRQuantifier(0, $3, @5, @1, yyscanner); > > + (errcode(ERRCODE_SYNTAX_ERROR), > The leading parenthesis is optional and can be removed, fewer > parentheses are always better. > See related discussion: > https://postgr.es/m/202510100916.s2e6n3xiwvyc@alvherre.pgsql Right. I will review all other patches. > Since v47-0001 introduces many ereport(ERROR) messages, it makes sense > to move the related regression tests from the other patch into > v47-0001, IMHO. Thanks for the suggestion but I do not agree the direction. It will make the patch maintenance work harder. Also it will make it difficult to understand the regression test organization. Regards, -- Tatsuo Ishii SRA OSS K.K. English: http://www.sraoss.co.jp/index_en/ Japanese:http://www.sraoss.co.jp