HOW TO CALL A ORACLE STORED PROCEDURE

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
mchaves
Participant
Posts: 50
Joined: Mon Aug 08, 2005 9:59 pm
Location: Sydney
Contact:

HOW TO CALL A ORACLE STORED PROCEDURE

Post by mchaves »

Hi there,

I know that this topic was covered before using odbc plug-in to call a stored procedure but it seems to me so sloppy. So I would like to know if there is any other way to call a oracle procedure in oracle oci plug-in.

I have tried calling the procedure in the after tab in oci plug-in but no success. The datastage gives me the error:

ORA-06576: not a valid function or procedure name

and my code is :

CALL PRC_REFRESH_ALL_MVIEWS;


Thanks mates
elavenil
Premium Member
Premium Member
Posts: 467
Joined: Thu Jan 31, 2002 10:20 pm
Location: Singapore

Post by elavenil »

There is one way(it may not be nice way) to execute the Oracle stored procudure by calling SQLPLUS utility in Jobcontrol using DSExecute.

HTWH.

Regards
Saravanan
roy
Participant
Posts: 2598
Joined: Wed Jul 30, 2003 2:05 am
Location: Israel

Post by roy »

Hi,
You simply need the full name shema name and all _ you must have the privilages to read/run it.
It has been a while so if call doesn't work try execute (or similar)
I did it a year ago with before and after sql with OCI stage it works fine.

IHTH,
Roy R.
Time is money but when you don't have money time is all you can afford.

Search before posting:)

Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Image
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Or upgrade to 7.5 so you have access to the Stored Procedure stage.
-craig

"You can never have too many knives" -- Logan Nine Fingers
roy
Participant
Posts: 2598
Joined: Wed Jul 30, 2003 2:05 am
Location: Israel

Post by roy »

Just clearing that you need Oracle 9+ for Craig's idea.
IHTH,
Roy R.
Time is money but when you don't have money time is all you can afford.

Search before posting:)

Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Image
mchaves
Participant
Posts: 50
Joined: Mon Aug 08, 2005 9:59 pm
Location: Sydney
Contact:

Post by mchaves »

Hi Mates,

I went for the sqlplus option. Thanks Saravanan. It's not that elegant but it's easier to implement.

Thanks all for the assistance. This forum is very useful.

Cheers,
Melquior
Post Reply