Use this tag for questions about the Spring JDBC SimpleJdbcCall class of multi-threaded, reusable objects representing a call to a stored procedure or a stored function.
Questions tagged [simplejdbccall]
37 questions
1
vote
1 answer
SimpleJdbcCall: Reading a CLOB returned from stored procedure
I have DAO function that calls DB procedure using SimpleJdbcCall. However i am unable to read the CLOB data returned from stored procedure. When i try to do a .toString() on the returned CLOB value ( result.get("OUT_RTN_XML") ), I just get this in…

Nick M
- 91
- 1
- 3
0
votes
0 answers
Can I call Postgres stored procedure utilizing Spring SimpleJdbcCall
I got below error when I call postgres stored procedure by utilizing spring's SimpleJdbcCall.
org.springframework.jdbc.BadSqlGrammarException: CallableStatementCallback;
bad SQL grammar [{call myProc(?, ?)}];
nested exception is…

user3593086
- 43
- 1
- 6
0
votes
0 answers
SimpleJdbcCall declareParameters and values in one line
I am coming from .NET to Java Spring Boot.
In .NET, I prefer to use ADO and stored procedures for my data access layers.
The closest Java equivalent I have found so far seems to be SimpleJdbcCall.
In .NET I can declare my params AND values going to…

Taylor Brown
- 1,689
- 2
- 17
- 33
0
votes
1 answer
Pass in/out JSON param to oracle stored procedure using simpleJdbcCall
I have stored procedure in Oracle. Here its defenition:
procedure pName(pObj in out JSON_OBJECT_T)
Example of calling it from dBeaver:
DECLARE
POBJ JSON_OBJECT_T;
BEGIN
POBJ := JSON_OBJECT_T.parse('{"cli_code" : "01.075648"}');
…

shoegazeSunshine
- 3
- 2
0
votes
0 answers
SimpleJdbcCall and PLS_INTEGER return type
i am using spring boot 2.7.4. I'm trying to call this oracle function:
FUNCTION GetKey(
p_table VARCHAR2
) RETURN PLS_INTEGER;
To do this, I'm using SimpleJdbcCall:
SimpleJdbcCall simpleJdbcCall = new SimpleJdbcCall(jdbcTemplate)
…

Lako12
- 154
- 1
- 10
0
votes
0 answers
Issue in executing postgreSQL function using SimpleJdbcCall in Java
I am calling postgreSQL function from Java using SimpleJdbcCall and extracting the output in ResultSet, while the function returns data when run in postgre but in Java it is giving null result.
Here is my postgre function that I am calling:
…

vedant
- 1
- 1
0
votes
2 answers
How should I change the code so as to not get this warning : Raw use of parameterized class
I am try to get the values from the results of a stored procedure using SimpleJdbcCall.
SimpleJdbcCall simpleJdbcCall = new SimpleJdbcCall(dataSource)
.withProcedureName("getCryptData");
SqlParameterSource in = new…

ZhongYu
- 53
- 4
0
votes
0 answers
@Autowired not working in my code - Objects values are null
I have created datasource bean in xml file and used @Autowired to datasource. But getting datasource object value 'null'. Because of @Autowired is not woking in whole code,all objects created in code are null which throws nullPointerException.
Here…

priya
- 13
- 5
0
votes
2 answers
Call procedure oracle with out parameters type "is table of varchar2" using java SimpleJdbcCall
I've created a procedure oracle with 2 parameters, one of them is a out parameter type TABLE OF VARCHAR2 . how to call it in java and get result?
My test procedure created below:
/* creating package with specs */
create or replace PACKAGE PACK1 AS
…

Dilermando Lima
- 1,004
- 8
- 21
0
votes
1 answer
Multiple SimpleJDBCCall beans causing Sonar issue in Java
My application is springboot and I am having DatabaseConfig where multiple SimpleJDBCCall beans are configured to execute stored proc and am having DAO where am injecting beans using constructor. This is working well, however this is failing on…

Wafa Saba
- 101
- 1
- 9
0
votes
1 answer
How pass VARRAY(oracle PL/SQL) param to procedure with simplejdbccall?
Here is VARRAY type :
CREATE TYPE NUM_ARR IS VARRAY(3) OF NUMBER(0)
;
Here is Procedure
PROCEDURE REGISTER_CONSENT(P_IPS_ACC_IBAN IN VARCHAR2,
P_IPS_BANK_BIC IN VARCHAR2,
P_STATUS_ID IN NUMBER,
…

Чингиз Намазов
- 3
- 2
0
votes
1 answer
How to call a stored procedure synchronously with SimpleJdbcCall
I was running a stored procedure with Springs SimpleJdbcCall like this:
SimpleJdbcCall jdbcCall = new SimpleJdbcCall(jdbcTemplate).withProcedureName("example_proc");
jdbcCall.execute();
// do other stuff on other subsystems
// the sysout below is…

Tamas Rev
- 7,008
- 5
- 32
- 49
0
votes
0 answers
How to call a PostgreSQL Stored Procedure with Spring SimpleJdbcCall and Fetch data from refcursor returned
I have a stored procedure in PostgreSQL that returns a refcursor and I want to call it using Spring Jdbc SimpleJdbcCall.
The procedure code is given below:
CREATE OR REPLACE FUNCTION show_emps() RETURNS refcursor AS $$
DECLARE
ref refcursor; …

Vishuu
- 1
- 5
0
votes
1 answer
SimpleJdbcCall to function returning null
we have build some program that call simplejdbccall to function and pull data from the postgres database. It is working fine when we are tested through main program
public class MainApp {
public static void main(String[] args) {
…

sachin
- 159
- 1
- 11
0
votes
1 answer
Unable to locate the corresponding parameter value for 'in_id' within the parameter values provided
I am trying to implement following tutorial https://www.tutorialspoint.com/spring/calling_stored_procedure.htm for simplejdbccall with postgres (need to migrate existing application from Oracle to Postgres which using simplejdbccall) but getting…

sachin
- 159
- 1
- 11