Home > database >  Sqlite is strict data sequence read
Sqlite is strict data sequence read

Time:09-28

Sqlite version is 3.7 and above
Insert into test (id) values (1);
Insert into test (id) values (2);
Insert into test (id) values (3);
Insert into test (id) values (4);
Insert into test (id) values (5);

Select * from the test;//a single table, do not do the order by
Id
-
1
2
3
4
5
Single table reads: sqlite is absolute to proceed with the order in accordance with the order of the insert data read, is it possible to read out data instead of 1, 2, 3, 4, 5, 2,1,3,5,4 such order?

CodePudding user response:

Is entirely possible, because a sqlite has index, is required to specify the order if you want to, must have the order by,,
  • Related