i beleive,
You can use dbms_pipe ( for embedding the OS commands) or JavaStoredProcedure or Just libraries.
anyhow to execute such a procedure u need to make use of external procedures ( Pro*c etc.)
from the docs
create library ora_nt is 'C:ntshell1.dll'
/
create or replace function ntshell(cmdin varchar2, arg1 varchar2, arg2 varchar2)
return binary_integer is
external library ora_nt
name "exec"
language C
parameters (cmdin string, arg1 string, arg2 string);
/
#include<stdio.h>
#include <stdlib.h>
#include <string.h>
#include <conio.h>
#include<process.h>
__declspec(dllexport) exec(char *cmdin, char *arg1, char *arg2)
{
if(spawnlp(P_NOWAIT, cmdin, cmdin, arg1, arg2, NULL) == -1) return -1;
return 1;
and usage is
SQL> select ntshell('cmd.exe','/c','del c:sig.txt') from dual;
[Updated on: Mon, 28 December 2009 11:55]
Report message to a moderator