Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Writing to named Pipes

Re: Writing to named Pipes

From: Mark Styles <lambicm_at_yahoo.com>
Date: Wed, 23 Sep 1998 14:19:54 GMT
Message-ID: <3609021e.22087039@news.intra.bt.com>


Wed, 23 Sep 1998 13:58:45 GMT, kjohnson29_at_my-dejanews.com rambled:

>I'm interested in creating a trigger that will write columns from the
>triggered row to a named pipe.	The process on the other side of the pipe is
>a non-PL/SQL program, likely written in C or PERL.  I had intended to use the
>UTL_FILE package to do this, if possible, but now I'm wondering about the
>DBMS_PIPE package.  Does anyone have any info on doing this?  Any example
>code?  Any reasons to use one method over the other?

DBMS_PIPE is a bit more flexible than UTL_FILE, as it doesn't require new init.ora parameters or anything.

Here is a package which can be used to write debug information to a pipe:

CREATE OR REPLACE PACKAGE trace AS

    PRAGMA RESTRICT_REFERENCES (trace_on,WNDS,RNDS);
    PRAGMA RESTRICT_REFERENCES (trace_off,WNDS,RNDS);
    PRAGMA RESTRICT_REFERENCES (trace_entry,WNDS);
    PRAGMA RESTRICT_REFERENCES (trace_exit,WNDS);
    PRAGMA RESTRICT_REFERENCES (trace_print,WNDS);
END trace;
/

CREATE OR REPLACE PACKAGE BODY trace AS

  PROCEDURE trace_on (b_pipe varchar2,

                      b_level integer default 0) IS
  BEGIN

  PROCEDURE trace_off IS
  BEGIN

  PROCEDURE trace_entry (b_name varchar2) IS   BEGIN

  PROCEDURE trace_exit (b_name varchar2) IS   BEGIN

  PROCEDURE trace_print (b_string varchar2, b_level integer default 0) IS
  BEGIN

Mark Styles
Spam my account, lose your account. Clear enough? Religious tolerance is an oxymoron. Received on Wed Sep 23 1998 - 09:19:54 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US