If a notification is sent in postgresql, how can I trigger a function by using listen? I know it can be done in another programming language, and I know you can send triggers after changes to tables, but how do I only trigger a function after a notification inside postgresql? Something like:
LISTEN <channel> THEN PERFORM ...