Check out the DBMS_PIPE package, this deals with inter-process communication.

HTH.

David.