I want call a procedure from my Java code to delete from database. Below is my Java code and exception
String procedureCall = "{call NEW_PORTING_PRC.delete_album_metadata(?)}";
CallableStatement cal = conn.prepareCall(procedureCall);
cal.setString(1, catId);
cal.registerOutParameter(2, oracle.jdbc.OracleTypes.VARCHAR);
cal.execute();
Exception is:
ERROR ["http-bio-8080"-exec-9] (Content_005fDelete_jsp.java:45) - [15-05-15 14:16:01,912] -
java.sql.SQLException: ORA-06550: line 1, column 7:
PLS-00306: wrong number or types of arguments in call to 'DELETE_ALBUM_METADATA'
ORA-06550: line 1, column 7:
PL/SQL: Statement ignored
Can anyone suggest where I am going wrong?
you are passing one parameter to the NEW_PORTING_PRC.delete_album_metadata
procedure and it's expecting a different number of parameters
or
you are passing a varchar where it is expecting a number, date etc
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.