Add note about using $1, $2, etc. for pg driver (#31)

This commit is contained in:
Paul Smith 2016-12-16 13:31:24 -05:00 committed by Brian J. Cardiff
parent 7d30e9f50e
commit 8e3bb19b6d

View file

@ -27,6 +27,7 @@ require "db"
require "sqlite3"
DB.open "sqlite3:./file.db" do |db|
# When using the pg driver, use $1, $2, etc. instead of ?
db.exec "create table contacts (name string, age integer)"
db.exec "insert into contacts values (?, ?)", "John Doe", 30