Is it possible to call a windows batch file from PL/SQL block ??
Hi gurus,
Would require your help.Is it possible to call a windows batch file from PL/SQL block ??If yes can you give an example for the same or any workaround for the same.
Regards
Vijay
You didn't specify a database version, but if you are 10g or higher, it's quite straightforward using an external job type in DBMS_SCHEDULER. Funnily enough i'm looking at something similar myself at the moment.
Useful guide to some of the issues here Guide to External Jobs on 10g with dbms_scheduler e.g. scripts,batch files
Similar Messages
-
Is it possible to call a windows batch file from PL/SQL
Hi gurus,
Would require your help.Is it possible to call a windows batch file from PL/SQL??If yes can you give an example for the same or any workaround for the same.
Regards
VijayHi!
Youn need some extproc related entries in you listener.ora and tnsnames.ora file.
*1. In the listener.ora:*
Defining the listener process is done in two parts.
The information contained in each listener differs!!!
The first part is as follows:
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = extproc)) <--- *ADD THIS LINE
(ADDRESS = (PROTOCOL = TCP)(HOST = yourhostname)(PORT = 1521))
)The seoncd part is as follows:
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = YOUR_GLOBAL_DBNAME)
(ORACLE_HOME = c:\oracle\product\10.2.0) <-- THIS IS YOUR ORACLE_HOME
(SID_NAME = YOUR_SID) <-- SID
(SID_DESC = <--- ADD THIS LINE
(SID_NAME = PLSExtProc) <--- ADD THIS LINE
(ORACLE_HOME = c:\oracle\product\10.2.0) <--- ADD THIS LINE AND EDIT TO YOUR ORACLE_HOME
(PROGRAM = extproc) <--- ADD THIS LINE
(ENV = "EXTPROC_DLLS=ANY") <--- ADD THIS LINE
) <--- ADD THIS LINE
)*2. In the tnsnames.ora you need to add the following entry:*
*(The KEY value entered must be match to the KEY value entered int the listener.ora file!)*
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = extproc))
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)Finally you need to restart your listiner. After restarting there will be a service called "PLSExtProc" in your listener.
This are only examples for extproc configuration, your tnsnames.ora and listener.ora can be differs.
FIRST MAKE MAKE A BACKUP OF YOUR ORIGINAL tnsnames.ora AND listener.ora FILES
For more information please check metalink note 68061.1 "EXTPROC: Creating External Procedures on Windows NT"
Bestr Regards
Norbert -
Calling a batch file from PL/SQL
Is there a way to call a windows batch file from within a stored
program in Oracle?
I need to check for error records in a table and if exists, I
would like to call a batch file that invokes mail server and
sends an error notification to a designated person..
Thanks in advanceRe: Upgrate problem
-
Call ggsci using batch file from windows- get error
i create a script to use ggsci, start manager, extract and replicat.
i have success doing this in my linux.
here is one of my script : start_ext1.sh
cd /u01/app/oracle/ggs
./ggsci <<EOF
start manager
start ext_s
exit
EOF
clear
i have an error when i do this using batch file from windows.
here is the batch file :
@echo off
cd C:\putty
plink.exe -ssh -2 -P 22 [email protected] -pw oracle "./start_ext1.sh"
every time i try to enter ggsci when i run that batch file, i get this error :
./ggsci: error while loading shared libraries: libnnz10.so: cannot open shared object file: No such file or directory
i didn't get this error when i run the script in linux.
is there anybody can help me?
thanks a lot!problem solved!
add : . ./.bash_profile before enter ggsci.
it's worked! :) -
Call Batch file from MAxl Script
Is it possible to call a windows batch file from a maxl script
If you look at the documentaion you will see there is a shell command available
-
Call batch file from Servlet.
Hi all,
can anybody tell me how to call or run batch file
from Servlet.
Please do hurry.class RuntimeClass
public static void main(String str[]){
Runtime JVM = Runtime.getRuntime();
try
JVM.exec("abc.bat");
catch(Exception e)
System.out.println("hello");
Hi,
i hope the above program will help. -
Call Oracle Stored Procedure with Parameters from Windows Batch File
Hi,
I have an oracle procedure that requires two parameters to execute, start date and end date as such:
CREATE OR REPLACE PROCEDURE insert_orders(
pSTART_DT IN varchar2
, pEND_DT IN varchar2
I want to create a windows batch file to execute the procedure but want to be able to specify the parameters (ie start and end dates) in the batch file as opposed to changing the sql file that the batch file uses to execute the procedure but I don't know what the syntax is. I tried the following but it still doesn't work.
Sql File: call_insert_orders.sql
execute insert_orders('&1','&2');
exit
Batch File:
sqlplus username/password @call_insert_orders.sql %01-jan-2010% %01-jan-2011%
When I execute the batch file, my DOS window still prompts me to enter value 1 so I think it recognizes that there is a variable being used but is not able to fill in the actual value I specify. I'm not an experienced DOS/Windows Batch File person so I'm guessing it's my syntax that's screwed up. There is not a lot of documentation on this subject matter hence my post on this forum. Any helps would be appreciated.
ThanksHello,
Just try the same DOS command without all the % sign.
In MS-DOS, the % at the beginning and at the end of a string are for variables. Which means your batch is looking for a variable called 01-jan-2010 and a variable called 01-jan-2011, but those are the values you want to pass, not the name of variables.
As they are not defined, nothing is passed to the sqlplus script, and that is why you are prompted for values.
Hope it will help.
Regards,
Sylvie -
Calling A Window's Program From Webforms
Is it possible to call a windows EXE program (such as NOTEPAD,
WINWORD, EXCEL, etc) from forms6.0 running on the web? This
should preferably be calling the programs residing in the CLIENT
PC rather than the APP SERVER machine. I tried using both HOST
and DDE commands, but both activate the programs on the server
side, and that these programs are shown in the TASK MANAGER but
never appeared in focus on the screen. Can someone please help?
Thanks.
Kelvin.
nullIs it possible to call a windows EXE program (such as NOTEPAD,
WINWORD, EXCEL, etc) from forms6.0 running on the web? This
should preferably be calling the programs residing in the CLIENT
PC rather than the APP SERVER machine. I tried using both HOST
and DDE commands, but both activate the programs on the server
side, and that these programs are shown in the TASK MANAGER but
never appeared in focus on the screen. Can someone please help?
Thanks.
Kelvin.
null -
Maxl within Windows Batch File
Hello,
I am trying to schedule an Automatic Essbase Archiving command . Function is to Disable connects , Archive , Unarchive and Enable connects . I know the Maxl commands which perform this action but just wanted to make sure how to portray this within a Windows Batch file.
Within the Batch file , abc.bat can I insert those commands . To enter the shell we need essmsh command , but I didnt wanted to get into decrypting , encrypting the ID etc to do that . So is there a way to get it done within the Windows batch file ?
Thanks !!Yes its Straight forward case ,create a batch file which call the maxl script.The batch file should contain the user id and password of Essbase and the maxl script should contain the parameters of Essbase archiving
The content of batch file for Essbase archiving process
echo off
set ESSUSER=admin
Set ESSPWD=Password
set ESSSERVER=localhost
set ESSAPP=Sample
set ESSDB=Basic
SET ESSBASE SERVER PATH=D:\Hyperion\Middleware\EPMSystem11R1\products\Essbase\EssbaseServer
set MaxlScript=D:\Hyperion\Middleware\user_projects\epmsystem1\Essbaseserver\essbaseserver1\bin
essmsh "D:\Archieve.mxl" %ESSUSER% %ESSPWD% %ESSSERVER%
===================================================================================================
Maxlscript Content for Archieving
spool on to "D:/bck.log";
set timestamp on;
login $ESSUSER $ESSPWD on $ESSSERVER;
display session all;
alter system kill request all;
alter system logout session all force;
export database $essApp.$essDB all data to server data_file 'd:\alldata.txt';
alter database $essApp.$essDB force archive to file "D:/sample.arc";
alter database $essApp.$essDB end archive;
spool off;
logout;
exit;
Similarly can you create batch files for Cube restoration .I hope the above example helps you
Thanks,
Sreekumar Hariharan -
Where windows batch file which log off windows lies ?
where windows batch file which log off windows lies ?
to which me can call from java code to log off my pc?You should use a brute-force algorithm on the on/off switch on your pc. I suggest a rate of 30 hits per minute.
-
Run a batch file from separate windows box to invoke DRM batch client
I need your suggestions on the following.
ODI & DRM are installed on separate boxes.
Now I want ODI to invoke a batch file (kept on DRM - Windows box, this batch file invokes DRM batch client to export the metadata). I tried using shared folder concept,but no success.
Any pointers please?This should work for you-
Create a batch file on your current server (ODI) and write in the path to the other batch file on the other server.
//Server2completename/D$/Path/yourbatchfile.bat
From ODI call your batch file that you created on the same machine.. which will inturn call the other batch file on a different machine to execute batch client.
Also can you paste the errors that you may be getting.. need to check if you are getting any specific issue related to this.
Thanks
Denzz -
Where windows batch file lies which log off windows ?
where windows batch file lies which log off windows ? wana log off my pc from java code
grc.com has a program (very small) that does it. The program is called "wizmo" and is written in Assembly.
If you are using Windows NT/2000/XP you can get a program in MS Windows Resource Kit called "shutdown.exe" but the program does only the shutdown job. You must manually turn the machine off. -
Is it possible to call the Print Quote functionality from Custom ADF page
Hi,
We are researching if it is possible to call the Print Quote functionality from the Custom ADF application.
Goal is to pop up the PDF report upon clicking the Print Quote button on the custom page. Is it possible ?
Atleast advice on the direction to go forward is appreciated.
Thanks
SaiHi ,
Please check following thread on forum -
Re: ADF: Calling OAF Page from ADF page
Check this may also be useful-
https://blogs.oracle.com/shay/entry/to_adf_or_oaf_or
I have not tried yet but Steven Chan (Sr. Director OATG) suggest following methodolgy for this-
https://blogs.oracle.com/stevenChan/entry/appsdatasource_jaas_ebs
Thanks,
Ashish -
Is it possible to call a locally installed ibook from a hyperlink? What about to a bookmarked page?
I have 2 questions..
1. Can I send a link via email that when launched will open an ibook that has already been downloaded to the bookshelf?
2. If question 1 is possible, can I take it a step further and call a bookmark, i.e. chapter 3.
Our company has it's own appstore and I want to send out links to sections of the ibooks using bookmarks or at the very least take them to the start of the ibook.
I don't need to give them a link to install the ibook as they already have it installed.
Any help would be much appreciated.
Chris.That would be cool, but it's not possible. The ibook is not accessible by URL in the user's bookshelf.
-
Is it possible to call std. SAP transaction from abap wd
Is it possible to call std. SAP transaction from abap wd so that transaction appears and work as in gui? Without portal ofcourse.
I know that using webgui and/or ITS it is possible so then it must be somehow possible....Hi,
see Web Dynpro ABAP call transaction in the foreground and just carry out a simple search in this forum, then you'll find several threads with similar questions...
Regards, Heidi
Maybe you are looking for
-
HOW COME it only asks to "delete files from PC" sometimes?
Sometimes when I am deleting items from my library it asks me if I want to remove from the pc or keep files. But other times it doesnt?
-
Using Weblogic Platform 7.0 (installed from platform700_win32.exe), Running a BPM Doamin(WLIDomain with BPM only). When I try to access my entity bean(CMP), the following exception is getting thrown. I have seen a similar post in here, but the answer
-
Graphic design for the web with ID
If I use ID to create web graphics can I export them without the page background? and if so can I change the page background colour so that I can see white when I am designing?
-
Dear All , I need two reports : 1) Open PO & open Pur req for the Period 2) Supplier Due to Deliver PO numbers Pl guide . Regards
-
Hi guys! I need to create some kind of report for my SD. It should contain all orders and first material availability date. This date is displayed in SD order in "all items" area as "first date" (data element name: ETDAT) I dont know how to find (sel