When compiling a plpgsql trigger function, include the OID of the table
the trigger is attached to in the hashkey. This ensures that we will create separate compiled trees for each table the trigger is used with, avoiding possible datatype-mismatch problems if the tables have different rowtypes. This is essentially the same bug recently identified in plpython --- though plpgsql doesn't seem as prone to crash when the rowtype changes underneath it. But failing robustly is no substitute for just working.
Showing
Please register or sign in to comment