sanoj subran
sanoj subran

Reputation: 406

How to select the next 50 records from a specified row in an SQLite table

Consider that my SQLite table has the following schema,

|'''''''''''''''''''''''''''''''''''''
| unique_id(TXT) | object_data(BLOB) |
|'''''''''''''''''''''''''''''''''''''
| | |
| | |
| | |
''''''''''''''''''''''''''''''''''''''

Assume that the row_id property is enabled, and so my question is, for a given unique_id, is it possible to fetch the next 50 records from the table, using a single SQL query? (Using the row_id property)

Upvotes: 1

Views: 203

Answers (1)

Aditya Bhosale
Aditya Bhosale

Reputation: 91

Try getting result through this method.

Select * from table_name [WHERE conditions] Limit 50 offset (Select row_id from table_name where unique_id = x);

Upvotes: 2

Related Questions