The reason you trigger "does nothing" is that you have it doing nothing in particular. Triggers are for:
1) validating data
2) checking constraints (when too complicated to do otherwise)
3) generate values for columns based on values in other tables
4) change (insert, update, delete) data in other tables based on table data
Your trigger is not persisting anything. Triggers cannot return result sets.
What I'm trying to do with the UDF is put some data in a MQSeries queue. I need to put some message when in the table some insert or update occurs. In thiscase the UDF is a function in the database wich invokes a function in a C program.
I have seen calling a UDF from a trigger is a valid action.
Well, I'm putting the MQSeries call (in a C lang. dll) in the UDF, and I would like the trigger call the UDF. I'm not interested in returning any result set.
If I can't call a Stored Procedure in a trigger (only OS/390) and I can't
make the UDF runs well from the trigger, I really don't know what I could do... maybe I'm not choosing the right way.