mirror of
https://gitea.invidious.io/iv-org/shard-crystal-sqlite3.git
synced 2024-08-15 00:53:26 +00:00
Update README.md for dynamic args (#53)
This commit is contained in:
parent
aed9acb225
commit
d9f916a598
1 changed files with 1 additions and 1 deletions
|
@ -26,7 +26,7 @@ DB.open "sqlite3://./data.db" do |db|
|
||||||
args = [] of DB::Any
|
args = [] of DB::Any
|
||||||
args << "Sarah"
|
args << "Sarah"
|
||||||
args << 33
|
args << 33
|
||||||
db.exec "insert into contacts values (?, ?)", args
|
db.exec "insert into contacts values (?, ?)", args: args
|
||||||
|
|
||||||
puts "max age:"
|
puts "max age:"
|
||||||
puts db.scalar "select max(age) from contacts" # => 33
|
puts db.scalar "select max(age) from contacts" # => 33
|
||||||
|
|
Loading…
Reference in a new issue