1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Fix another problem with ALTER TABLE and UPDATE...FROM in triggers.

FossilOrigin-Name: 33cf12235e6469ba17cfb72cef0e480dfd0dea81ed412fb1fb24b05dbeb8dc02
This commit is contained in:
dan
2022-05-27 15:33:51 +00:00
parent 4209d553e7
commit ca29bbce2f
5 changed files with 34 additions and 13 deletions

View File

@ -21,6 +21,7 @@ ifcapable !altertable {
return
}
set ::TMPDBERROR [list 1 \
{unable to open a temporary database file for storing temporary tables}
]
@ -47,6 +48,7 @@ do_faultsim_test 1 -prep {
faultsim_test_result {0 {}} $::TMPDBERROR
}
#-------------------------------------------------------------------------
# dbsqlfuzz e3dd84cda3848016a6a6024c7249d09bc2ef2615
#
@ -59,6 +61,11 @@ do_execsql_test 2.0 {
SELECT a FROM cte1
), 1);
END;
CREATE TRIGGER r1 AFTER INSERT ON t2 BEGIN
UPDATE t2 SET k=1 FROM t2 AS one, t2 AS two NATURAL JOIN t2 AS three
WHERE one.k=two.v;
END;
}
faultsim_save_and_close