Thank you very much for your help! Unluckily I can't get rowids on views.
sqlite does not declare an error, when I select rowid, * on a view. - It
just prints this column empty!
The problem is, that I have to sort first and then the numbering. So I can't
use the table rowids of the base table. Please let me know, if there's any
kind of workaround for this...
A couple things to try:
* Assign row id's in your code when you retrieve the results, not in
the select statement
* Select the sorted results into a temporary table then use a select,
not a view, to retrieve them. The rowid will be applied after the sort
Sorry, I didn't understand your problem well enough to give you a
better solution.
I thought all you needed was just to use the row and line columns to determine
the predecessor.