Always create unlogged IMMVs

This commit is contained in:
Jamal-B 2025-03-24 14:33:05 +01:00
parent 437b2d22d7
commit 69c5254a76

View file

@ -241,6 +241,9 @@ ExecCreateImmv(ParseState *pstate, CreateTableAsStmt *stmt,
bool do_refresh = false;
ObjectAddress address;
/* For mdpt purposes, we always create unlogged IMMVs */
into->rel->relpersistence = RELPERSISTENCE_UNLOGGED;
/* Check if the relation exists or not */
if (CreateTableAsRelExists(stmt))
return InvalidObjectAddress;