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

Home -> Community -> Usenet -> c.d.o.tools -> Re: Executing a com file

Re: Executing a com file

From: john sprague <bearpig_at_attglobal.net>
Date: Tue, 26 Jun 2001 20:41:23 -0500
Message-ID: <3B3939C3.64733B52@attglobal.net>

WANNIX wrote:

> We are running on a open vms computer using oracle 7 and I want to be able to
> execute a commnand file from a trigger or a pl/sql procedure. Is this
> possible?

It is possible . The .com file is the vms DCL code if I recall. Powerful - and handy for physically moving files and other mundane utlities.

However - you need some sort of execution environment to get the code 'outside.' I'm fortunate to have inherited a batch submitter that is able to submit code though a system queue . This batch submitter works like a deamon by reading a control table, grabbing whatever is stuck inside it , and executing the code. So - my proceedure/triggers can plant a path to the .com file into the batch submitter and that code is then executed on its own thread.

    Now - I know this can be done. I do not know specifically how to accomplish this vms task. I suspect the core code is an OCI routine that runs as a listener. It is necesssary to bring the bacth submitter on-line by running its executable at a command prompt.

    I suspect it would be possible to build a pro-c routine to do the same. Code runs an sniffs a control table. grabs whatever it finds and submits it to a specific execution queue just as a C routine can run on the VMS box and spawn its own child routines.

    This is not a trivial matter to do well with the logging and management features to let you system admin people handle its operation. The identiy of the batch submitter has its own permissions and roles for example - so it is necessary to treat it just like a user for maintence and the like.

 So - I can say it is possible - but it needs a type of manager program to run on the server that handles the spawning of these items. Orcale poulates the driving table with the keys to the car - and the batch submitter drives it.

jds Received on Tue Jun 26 2001 - 20:41:23 CDT

Original text of this message

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