on 01-21-2008 7:48 PM
Hi All,
I have a requirement of executing one stored procedure before putting data in Table through JDBC adaptor and two stored procedures after that.
I was thinking to write a shell script and execute it before and after message processing in adaptor.
Can anybody please tell me how should i write a shell script for it?
I have identified that exec <Stored_Proc_Name> is the syntax for it.
Will i need to write something more in this script?
Thanks,
Atul
Hi Atul,
Stored procedures are written on the Database server for which you are going to write JDBC adapter.
you will just call the storedprocedure in to your adapter.
as per your requirement you shd run one stored procedure (let us say SP1) and then you have to push data into tables and then run SP2 and SP3...
so for this write three stored procedures and call them into another SP. in this SP you call SP1 first then insert statement to insert data into tables and then SP2 and SP3.
finally call SP into your JDBC adapter.
you can call SP1 in SP as below
Var_SQL :='call SP1 (''' || Var_1 || ''',''' || Var_2 ||''')' ;
EXECUTE IMMEDIATE Var_SQL;
i think for this shell script is not required.. correct me if i am wrong...
Regards,
Sukarna.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sukarna,
Thanks for ur reply.
My problem is The scenario File to JDBC already exists. Only thing i want to change is call stored procedures. In that case i will have to change many things if i follow ur approach.
So i want to call stored proc in OS command only.
If i want to call a stored procedure in JDBC adaptor how can i do it?
Thanks,
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.