sraoss / pgsql-ivm

IVM (Incremental View Maintenance) development for PostgreSQL
Other
129 stars 12 forks source link

crash when the columns of the created materialized view do not match #149

Closed yugo-n closed 1 year ago

yugo-n commented 2 years ago

crash when the columns of the created materialized view do not match.

Create table t( a int); create incremental materialized view s(z) as select sum(1) as a, sum(1) as b from t;

yugo-n commented 2 years ago

Reported by huyajun in https://www.postgresql.org/message-id/tencent_FCAF11BCA5003FD16BDDFDDA5D6A19587809%40qq.com

The problem should be that colNames in rewriteQueryForIMMV does not consider this situation.