When a user load a new table in the Postgres System? Can a script> automatically detect it and run?>> Are you looking for Even triggers?https://www.postgresql.org/docs/current/event-triggers.html
Regards,Jay