All Apps and Add-ons

Splunk DB Connect: Input and temp tables

kbcall
Explorer

We have a very complex query that creates temp tables and declares variable. We can execute the SQL in Splunk and it returns the correct results but it will not allow us to save the SQL. Is there any way to work around using temp tables with DB connect inputs?

0 Karma
1 Solution

tmuth_splunk
Splunk Employee
Splunk Employee

It would help to know what database. If it’s one of the DBs that DBX supports for stored procedures, you could wrap all of your logic in a stored proc, then call that from DBX.

View solution in original post

0 Karma

tmuth_splunk
Splunk Employee
Splunk Employee

It would help to know what database. If it’s one of the DBs that DBX supports for stored procedures, you could wrap all of your logic in a stored proc, then call that from DBX.

0 Karma

kbcall
Explorer

MS SQL 2012 is our Database. In the previous version we tried a simple exec sp_who but DBConnect would not accept that as an input. Does DBConnect now support running stored procedures as inputs?

0 Karma

sochsenbein
Communicator

@tmuth We are still having this issue where the stored procedures are returning no results when they use temp tables. We are running Splunk version 7.0.0 and DB 3.0. Any advice?

0 Karma

kelseycasco
New Member

I am also having this problem.. the db_connect_server log says "A processing error "Invalid object name"

0 Karma

tmuth_splunk
Splunk Employee
Splunk Employee

Yes, DBX 3.x supports stored procedures. I’m mobile or I would send a direct link to the doc for it.

0 Karma

kbcall
Explorer

Thanks. I retired a simple stored procedure and I was able to save it as an input. We will experiment more with a more completed stored procedure.

0 Karma
Get Updates on the Splunk Community!

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...

What's new in Splunk Cloud Platform 9.1.2312?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.1.2312! Analysts can ...