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!

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...

.conf24 | Personalize your .conf experience with Learning Paths!

Personalize your .conf24 Experience Learning paths allow you to level up your skill sets and dive deeper ...

Threat Hunting Unlocked: How to Uplevel Your Threat Hunting With the PEAK Framework ...

WATCH NOWAs AI starts tackling low level alerts, it's more critical than ever to uplevel your threat hunting ...