Reputation: 15
For example I execute SELECT
query which result is set of rows R
. Is any way to drop from R
rows that satisfied condition which depends on last row of R
? Before executing SELECT
query the condition is unknown. I thought about some PROCEDURE
but i can't write it :(. Anyone can help? :).
Upvotes: 0
Views: 38
Reputation: 2097
Insert your query into a temp table: http://www.sqlite.org/lang_createtable.html
then select again from your table based on the last_insert_rowid of the temp table: https://sqlite.org/lang_corefunc.html#last_insert_rowid
Upvotes: 1