Re: PL/SQL calls windows service
Date: 7 Jan 2005 04:50:10 -0800
Message-ID: <1105102210.386521.174920_at_f14g2000cwb.googlegroups.com>
PMC wrote:
> Sorry Dan. Here's my environment,
>
> Windows 2000
> Oracle 8i
>
> The windows service has been written by me using VB.NET .
> It will be great if anyone can help me with DBMS_PIPE.
>
> Thanks!
[Quoted] Since you are on 8i and if you have JServer installed, you can also use Java's Runtime object to run OS commands. e.g. compile and test this from a command line by passing any valid OS command or an executable/batch file as first parameter. You can easily modify and load this in the database as Java stored procedure.
import java.lang.*; import java.io.*; import java.util.*;
public class RuntimeTest {
private static final String dquote = (char)34 +"";
public static void main (String[] args)
throws Exception {
Runtime r = Runtime.getRuntime();
Process p = r.exec("cmd /c " + dquote + args[0] + dquote);
p.waitFor();
}
}
Regards
/Rauf
Received on Fri Jan 07 2005 - 13:50:10 CET