06-29-2006 9:43 PM
Hi Gurus,
I'm working with Native SQL, trying to execute a function (NOT a procedure) present in an Oracle Database.
I have the DBCO table ready and the conection is working fine, but when I want to execute the function I get the following error (with short dump):
Database error text: "ORA-00900: invalid SQL statement"
Database error code: 900
Triggering SQL statement:
:VALIDO := cai_valido_i ? , ? , ? , ? , ? , ? )"
Looks like this is a syntax error when i'm trying to use the function. I try to call the function with EXECUTE PROCEDURE, but another error appear, saying that the procedure doesn't exist.
This is the function that I need to call in Oracle:
cai_valido_i
(ccai in number,
ccuit in number,
cfecha in date,
ccod_tc in number,
cpto_vta in number,
cnro in number) return number
I Hope somebody can help me with this.
Kind regards,
Roberto.-
06-29-2006 11:38 PM
Not sure how to call Functions but I executed procedures as below:
EXEC SQL PERFORMING <SAP_SUBROUTINE>.
SELECT <PROCEDURE>(
:<IN_PAR1>,
:<IN_PAR2>,
:<IN_PAR3>)
INTO :<OUT_PAR1>
FROM DUAL
ENDEXEC.
Thnaks,
Shashi Reddy
06-30-2006 2:12 PM