In SQLite, triggers may contain four types of statements: insert, update, delete, and select. What is the use of the select statement, namely, how can I access the result-set of the select statement?
For example, with the following setup,
create table "Data" ("data" Text); create trigger "Data-AI" after insert on "Data" begin /* some insert, update, or delete statements */ select "data" as "selected" from "Data" where length("data") < 4; -- assume that there at least two rows in the result set /* some insert, update, or delete statements */ end;
how can I use
"selected" in the second batch of insert, update, or delete statements?