Getting Data In

Splunk DB Connect: Can the checkpoint value be used in query?

cherryng
New Member

I am adjusting the SQL statement for data input. There is a guideline to use rising input mode.

SELECT * FROM your_table
WHERE dtime > ?
ORDER BY dtime ASC

How to use the checkpoint value (?) also as upper limit? Say
... WHERE dtime > ? AND dtime < ? + INTERVAL '1 day'

Labels (1)
0 Karma

jscraig2006
Communicator

I've ran across this several times when our databases that do not have a rising column or incrementing ID (Primary Key). Our solution was to change these to batch and query records between datetime and set the DB connect to query to the record time.. example if i grab the last 15 mins of records then I would set the DB connect to query every 15 mins.
The rising column has to be numeric. There maybe some better answers out there. This has always worked for us.

0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

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 ...