Re: change regexp_substr first argument make tests more easier to understand.
Tomas Vondra <tomas.vondra@enterprisedb.com>
From: Tomas Vondra <tomas.vondra@enterprisedb.com>
To: jian he <jian.universality@gmail.com>,
PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2024-07-18T21:49:16Z
Lists: pgsql-hackers
Hi, If I understand correctly, the problem is that it's not clear which of the 'abc' substrings is matched/returned by the function, right? I wonder if this is a problem only for understanding the test, or if it makes the tests a bit weaker. I mean, what if the function returns the wrong substring? How would we know? Also, if we tweak this, shouldn't we tweak also the regext_instr() calls a bit earlier in the test script? regards -- Tomas Vondra EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company