Data update
This commit is contained in:
parent
81fd053722
commit
52a6ef48dd
10248 changed files with 63654 additions and 6775 deletions
|
|
@ -1,19 +0,0 @@
|
|||
using SQLite
|
||||
|
||||
name = "Smith, Steve"
|
||||
jerseys = Dict("Smith, Steve" => 99)
|
||||
sqlbool(tf::Bool) = if(tf) "TRUE" else "FALSE" end
|
||||
|
||||
db = SQLite.DB() # no filename given, so create an in-memory temporary
|
||||
SQLite.execute!(db, "create table players (id integer primary key,
|
||||
name text,
|
||||
score number,
|
||||
active bool,
|
||||
jerseynum integer)")
|
||||
|
||||
SQLite.query(db, "INSERT INTO players (name, score, active, jerseynum) values ('Jones, James', 9, 'FALSE', 99)")
|
||||
SQLite.query(db, "UPDATE players SET name = ?, score = ?, active = ? WHERE jerseynum = ?";
|
||||
values = ["Smith, Steve", 42, sqlbool(true), jerseys[name]])
|
||||
|
||||
tbl = SQLite.query(db, "SELECT * from players")
|
||||
println(tbl)
|
||||
Loading…
Add table
Add a link
Reference in a new issue