2009/8/19 John Machin <sjmac...@lexicon.net>: > On 20/08/2009 12:57 AM, Kit wrote: >> Right form (tested): >> >> SELECT petr4.data AS data,petr4.preult AS preult,temp.data AS >> previous_data,temp.preult AS previous_preult >> FROM petr4,petr4 AS temp >> WHERE petr4.rowid=temp.rowid+1; > > Don't you think that relying on (a) rowid being consecutive (b) rowid > order being identical to date order is just a little bit dodgy? What if > the table has been created by a bulk load, not necessarily in ascending > date order? What if some rows have been deleted?
OK, you found more better solution. -- Kit _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users