sraoss / pg_ivm

IVM (Incremental View Maintenance) implementation as a PostgreSQL extension
Other
854 stars 24 forks source link

Consider tuple duplicity in maintenance of EXISTS views #83

Closed yugo-n closed 4 months ago

yugo-n commented 4 months ago

When a tuple is inserted into a table in an EXISTS subquery, the duplicity of row is computed by count(*), but it was not considered and only one tuple was inserted with ignoring the duplicity.

This is fixed by duplicating rows as much as the duplicity by using generate_series at inserting.

(Issue #82)