All Apps and Add-ons

Hi, can someone help me I need to execute the below stored procedure in Splunk

mlindokuhle
Loves-to-Learn Lots

CREATE OR REPLACE PROCEDURE BSDTADLS.DMS_Main
(Query_type in varchar,
query_id in varchar,
outResults out sys_refcursor
)
as


BEGIN

IF upper(Query_type) = 'F'
THEN
open outResults for
select distinct A.J_BACI, A.J_BAGT, A.J_BAZC, A.J_BBS_,A.J_BAJ8,A. J_BAO8, B.J_MBTI , c.J_NOHT
from J_COM A
left join J_CLMS B ON A.J_BACI = B.J_MBXI
inner join J_CTUN c on A.J_crpi = c.J_NOGI and c.J_NOFC = '02'
WHERE A.J_BACI = query_id;

ELSIF upper(Query_type) = 'L'
END IF ;

END DMS_Main;
open outResults for SELECT distinct A.J_MBTI ,A.J_MEE_,A.J_MCFC,A.J_MCI8,A.J_MCJ8,B.J_Mvfi, B.J_MVGT
from J_CLMS A
Inner join J_CUPI B
ON A.J_MBWI = B.J_MVAI
WHERE A.J_MBTI = query_id;
ELSIF upper(Query_type) = 'A'

Labels (2)
0 Karma

saravanan90
Contributor

This may help..

https://docs.splunk.com/Documentation/DBX/3.0.2/DeployDBX/Commands#procedure

--------------------

An upvote would be appreciated if the above reply is useful to you.

 

0 Karma

richgalloway
SplunkTrust
SplunkTrust

Splunk can't do that.  SQL stored procedures only run on SQL databases.

---
If this reply helps you, Karma would be appreciated.
0 Karma
Get Updates on the Splunk Community!

Index This | When is October more than just the tenth month?

October 2025 Edition  Hayyy Splunk Education Enthusiasts and the Eternally Curious!   We’re back with this ...

Observe and Secure All Apps with Splunk

  Join Us for Our Next Tech Talk: Observe and Secure All Apps with SplunkAs organizations continue to innovate ...

What’s New & Next in Splunk SOAR

 Security teams today are dealing with more alerts, more tools, and more pressure than ever.  Join us for an ...