Reading only the data that's not been previously read

I need to read data from a measurement that’s being written to at the same time. I don’t want to read data I’ve read before, so how to I set each query to start from where the previous left off.

Say I have writes

one
two
three
four
five
six
seven
eight
nine
etc…

Say that on the first read, values one through five are retrieved (because, at the time, five was the latest entry). How do I set the query so that the next read gets values six through nine (or whatever the most recent one is), and so on.

Thanks.

Hello @JasonJ55,
What version of InfluxDB are you using?
Either way I dont think there’s a way to do this with InfluxQL or SQL. You could use a flux task to write an index to your data points and then query based off of the index but there ins’t a way to do that with just a query.