Обсуждение: pgsql: Resolve partition strategy during early parsing
Resolve partition strategy during early parsing This has little practical value, but there's no reason to let the partition strategy names travel through DDL as strings. Reviewed-by: Japin Li <japinli@hotmail.com> Discussion: https://postgr.es/m/20221021093216.ffupd7epy2mytkux@alvherre.pgsql Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/5fca91025e05f803140831953c09a36f08efcef5 Modified Files -------------- src/backend/commands/tablecmds.c | 35 +++++++++++------------------------ src/backend/parser/gram.y | 22 +++++++++++++++++++++- src/backend/partitioning/partbounds.c | 27 +++++---------------------- src/backend/utils/cache/partcache.c | 6 ++++++ src/include/nodes/parsenodes.h | 15 ++++++++------- src/include/partitioning/partbounds.h | 2 +- src/include/utils/partcache.h | 3 ++- 7 files changed, 54 insertions(+), 56 deletions(-)
On Thu, Nov 03, 2022 at 03:41:56PM +0000, Alvaro Herrera wrote: > Resolve partition strategy during early parsing > > This has little practical value, but there's no reason to let the > partition strategy names travel through DDL as strings. > > Reviewed-by: Japin Li <japinli@hotmail.com> > Discussion: https://postgr.es/m/20221021093216.ffupd7epy2mytkux@alvherre.pgsql > > Branch > ------ > master > > Details > ------- > https://git.postgresql.org/pg/commitdiff/5fca91025e05f803140831953c09a36f08efcef5 This caused a warning in MSVC. [16:10:46.225] c:\cirrus\src\backend\parser\gram.y(18435) : warning C4715: 'parsePartitionStrategy': not all control pathsreturn a value I'll send a patch to make cfbot warn about that soon.
On Sat, 5 Nov 2022 at 05:19, Justin Pryzby <pryzby@telsasoft.com> wrote: > [16:10:46.225] c:\cirrus\src\backend\parser\gram.y(18435) : warning C4715: 'parsePartitionStrategy': not all control pathsreturn a value I noticed this too. I've just pushed a patch to fix it. David