I assume we want to know if a Var is nullable with a function like. is_var_notnullable(Var *var, Relids relids). If so, we can define the data as below:struct RelOptInfo {Bitmapset** notnullattrs;..}; After this we can implement the function as: boolis_var_notnullable(Var* var, Relids relids){ RelOptInfo *rel = find_rel_by_relids(reldis); return bms_is_member(var->varattno, rel->notnullattrs[var->varno]);}Probably we can make some hackers to reduce the notnullattrs's memory usageoverhead.
pgsql-hackers by date:
Соглашаюсь с условиями обработки персональных данных