Lines Matching full:create

14 # 1. CREATE and DROP TRIGGER tests
23 # trig-1.9: Ensure that we cannot create a trigger on sqlite_master
36 CREATE TRIGGER trig UPDATE ON no_such_table BEGIN
43 CREATE TEMP TRIGGER trig UPDATE ON no_such_table BEGIN
50 CREATE TABLE t1(a);
53 CREATE TRIGGER tr1 INSERT ON t1 BEGIN
59 CREATE TRIGGER tr1 DELETE ON t1 BEGIN
68 CREATE TRIGGER tr2 INSERT ON t1 BEGIN
71 CREATE TRIGGER tr2 INSERT ON t1 BEGIN
79 CREATE TRIGGER tr1 DELETE ON t1 BEGIN
108 CREATE TEMP TABLE temp_table(a);
112 CREATE TRIGGER temp_trig UPDATE ON temp_table BEGIN
121 CREATE TRIGGER tr1 AFTER UPDATE ON sqlite_master BEGIN
125 } {1 {cannot create trigger on system table}}
133 create table t1(a,b);
138 create trigger r1 after delete on t1 for each row begin
148 create table t1(a,b);
153 create trigger r1 after update on t1 for each row begin
162 # Ensure that we cannot create INSTEAD OF triggers on tables
165 create table t1(a,b);
166 create trigger t1t instead of update on t1 for each row begin
170 } {1 {cannot create INSTEAD OF trigger on table: t1}}
171 # Ensure that we cannot create BEFORE triggers on views
174 create view v1 as select * from t1;
175 create trigger v1t before update on v1 for each row begin
179 } {1 {cannot create BEFORE trigger on view: v1}}
180 # Ensure that we cannot create AFTER triggers on views
184 create view v1 as select * from t1;
185 create trigger v1t AFTER update on v1 for each row begin
189 } {1 {cannot create AFTER trigger on view: v1}}
195 CREATE TRIGGER r1 AFTER INSERT ON t1 BEGIN
202 CREATE TRIGGER r1 AFTER INSERT ON t1 BEGIN
209 # Create a trigger that refers to a table that might not exist.
213 CREATE TEMP TABLE t2(x,y);
216 CREATE TRIGGER r1 AFTER INSERT ON t1 BEGIN
241 CREATE TEMP TABLE t2(x,y);
249 CREATE TEMP TRIGGER r1 AFTER INSERT ON t1 BEGIN
259 CREATE TABLE t2(x,y);
280 CREATE TEMP TRIGGER r1 BEFORE INSERT ON t1 BEGIN
313 # Create a trigger with the same name as a table. Make sure the
322 CREATE TRIGGER t2 BEFORE DELETE ON t2 BEGIN
361 CREATE TRIGGER 'trigger' AFTER INSERT ON t2 BEGIN SELECT 1; END;
373 CREATE TRIGGER "trigger" AFTER INSERT ON t2 BEGIN SELECT 1; END;
385 CREATE TRIGGER [trigger] AFTER INSERT ON t2 BEGIN SELECT 1; END;
400 CREATE TABLE t3(a,b);
401 CREATE TABLE t4(x UNIQUE, b);
402 CREATE TRIGGER r34 AFTER INSERT ON t3 BEGIN
428 # example, that you can drop and re-create tables referenced by triggers.
433 execsql {CREATE TABLE t3(a, b, c);} db2
441 CREATE TABLE t1(a, b, c);
442 CREATE temp TABLE t2(a, b, c);
443 CREATE TABLE insert_log(db, a, b, c);
448 CREATE TEMP TRIGGER trig1 AFTER INSERT ON t1 BEGIN
451 CREATE TEMP TRIGGER trig2 AFTER INSERT ON t2 BEGIN
454 CREATE TEMP TRIGGER trig3 AFTER INSERT ON t3 BEGIN
499 # Drop and re-create the insert_log table in a different database. Note
504 CREATE temp TABLE insert_log(db, d, e, f);