lsqlthw ex7
This commit is contained in:
parent
bf4f303f5a
commit
9bd505e7a3
11
lsqlthw-remnants/ex7.sh
Executable file
11
lsqlthw-remnants/ex7.sh
Executable file
@ -0,0 +1,11 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
set -e
|
||||||
|
set -x
|
||||||
|
|
||||||
|
rm -f ex3.db
|
||||||
|
sqlite3 ex3.db < ex2.sql
|
||||||
|
sqlite3 ex3.db < ex3.sql
|
||||||
|
sqlite3 ex3.db < ex4.sql
|
||||||
|
sqlite3 ex3.db < ex5.sql
|
||||||
|
sqlite3 ex3.db < ex6.sql
|
||||||
|
sqlite3 -echo ex3.db < ex7.sql
|
9
lsqlthw-remnants/ex7.sql
Normal file
9
lsqlthw-remnants/ex7.sql
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
SELECT name, age FROM pet WHERE dead = 1;
|
||||||
|
|
||||||
|
DELETE FROM pet WHERE dead = 1;
|
||||||
|
|
||||||
|
SELECT * FROM pet;
|
||||||
|
|
||||||
|
INSERT INTO pet VALUES (1, "Gigantor", "Robot", 1, 0);
|
||||||
|
|
||||||
|
SELECT * FROM pet;
|
Loading…
Reference in New Issue
Block a user