@ptarjan I was mistaken about raise_notice. This seems to work with the test case described.