github sraoss/pg_ivm v1.17
pg_ivm 1.17 (2026-10-18)

3 hours ago

What's Changed

New features

  • Add replace option to restore_immv() by @yugo-n in #186

    Allow restore_immv() to replace existing IMMV metadata entries. Add a --pg-upgrade option to pg_ivm_dump_metadata to generate restore commands that can be used with pg_upgrade. Previously, restoring IMMVs after pg_upgrade failed because old IMMV entries remained in pg_ivm_immv.

Bug fixes

  • Fix incorrect ispopulated state after restore_immv() by @playments-admin in #187

    restore_immv() incorrectly left ispopulated = false after restoring an IMMV. As a result, a later refresh_immv() could add a duplicate set of IVM triggers, causing incorrect view maintenance.

  • Improve unique key derivation for automatic index creation by @yugo-n in #183

    Derive unique keys from the original view definition instead of the rewritten query. This enables automatic index creation for
    queries where uniqueness can be determined from the original query shape, such as queries containing EXISTS clauses.

    Also reject target lists containing set-returning functions, since such queries cannot have a unique key even when all primary key columns are present. In addition, ignore subqueries without range table entries, since they produce at most one row when they do not contain set-returning functions.

    Replace the DETAIL message reported when automatic index creation fails with a more general description, since the reasons
    preventing unique-key derivation can be complex.

  • Fix crash during index creation with LATERAL subqueries by @yugo-n in #183

  • Fix assertion failure in check_immv_compatibility() by @yugo-n in #185

New Contributors

Full Changelog: v1.16...v1.17

Don't miss a new pg_ivm release

NewReleases is sending notifications on new releases.