Hello,
I recently recompiled my app with SQLCipher 1.50 (Last time I used it I was using 1.30 I think). One of my query doesn't work anymore. You can see the attached example, the "OFFSET" returns the wrong result.
Previously, it would work like: rows 1-10, 11-20, 21-30 .... 991-1000.
But now I get: 1-10, 1-20, 1-30, .... 1-1000.
I have tried with different queries:
But both fail.
Using "LIMIT" only works as expected:
1-10
...
1-10
I haven't kept the old SQLCipher version, so I can't confirm that it was working properly before. But it did for the past 5 years? I Haven't changed the code apart from that. It's not only me, my users also noticed the problem. :-S
Thank you for your help.
Jmon
Note: The example creates a DB with 1000 records in it. Pressing the button, should write selected records in the label, each time the button is pressed.
Expected result is:
OFFSET IS AT= 30
rowCount= 10 (Should be : 10)
row0030
row0031
....
row0039
but I get:
OFFSET IS AT= 30
rowCount= 30 (Should be : 10)
row0001
row0002
....
row0039
I recently recompiled my app with SQLCipher 1.50 (Last time I used it I was using 1.30 I think). One of my query doesn't work anymore. You can see the attached example, the "OFFSET" returns the wrong result.
Previously, it would work like: rows 1-10, 11-20, 21-30 .... 991-1000.
But now I get: 1-10, 1-20, 1-30, .... 1-1000.
I have tried with different queries:
SELECT bar FROM foo ORDER BY bar ASC LIMIT ${limit} OFFSET ${offset};
(http://www.sqlitetutorial.net/sqlite-limit/)SELECT bar FROM foo ORDER BY bar ASC LIMIT ${offset},${limit};
But both fail.
Using "LIMIT" only works as expected:
1-10SELECT bar FROM foo ORDER BY bar ASC LIMIT ${limit};
1-10
...
1-10
I haven't kept the old SQLCipher version, so I can't confirm that it was working properly before. But it did for the past 5 years? I Haven't changed the code apart from that. It's not only me, my users also noticed the problem. :-S
Thank you for your help.
Jmon
Note: The example creates a DB with 1000 records in it. Pressing the button, should write selected records in the label, each time the button is pressed.
Expected result is:
OFFSET IS AT= 30
rowCount= 10 (Should be : 10)
row0030
row0031
....
row0039
but I get:
OFFSET IS AT= 30
rowCount= 30 (Should be : 10)
row0001
row0002
....
row0039