All Apps and Add-ons

SQL Truncate Query

Gregg123
Engager

Hi Guys,
I'm using Splunk with DB Connector and all seem to work fine. The only problem is that when I go to "Run SQL queries" and click on the DB Query button to execute Truncate statement (I'm connected to Postgres DB) the command doesn't actually do anything and data stays in the table. Selecting and other queries work fine. What seems to be a problem?
When I set up the connection I did select the dialect to be Postgres so such typical for Postgres query should be understood. And, I'm an admin so I do have privileges to delete (truncate) tables.
Any suggestions?
Thanks
Greg

Tags (2)

Gregg123
Engager

Yes, I'm perfectly aware of this fact. If dbconnect is in read only mode such query will cause an error to appear at the top of the browser's window. So, Splunk will actually inform you about this, and states that this is read only connection etc.
I fixed that, and this isn't a problem.
Something else prevents Truncate query to be executed.

0 Karma

yannK
Splunk Employee
Splunk Employee

Are you aware that by default dbconnect only has only read permissions on the database ?
see
http://docs.splunk.com/Documentation/DBX/latest/DeployDBX/Addadatabaseconnection

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Take Action Automatically on Splunk Alerts with Red Hat Ansible Automation Platform

 Are you ready to revolutionize your IT operations? As digital transformation accelerates, the demand for ...

Calling All Security Pros: Ready to Race Through Boston?

Hey Splunkers, .conf25 is heading to Boston and we’re kicking things off with something bold, competitive, and ...

Beyond Detection: How Splunk and Cisco Integrated Security Platforms Transform ...

Financial services organizations face an impossible equation: maintain 99.9% uptime for mission-critical ...