mirror of
https://gitea.invidious.io/iv-org/shard-crystal-db.git
synced 2024-08-15 00:53:32 +00:00
Fix docs
This commit is contained in:
parent
c096294496
commit
5697bd5c58
1 changed files with 2 additions and 2 deletions
|
@ -178,7 +178,7 @@ module DB
|
||||||
# read as a tuple of the given *types*.
|
# read as a tuple of the given *types*.
|
||||||
#
|
#
|
||||||
# ```
|
# ```
|
||||||
# contacts = db.query_all "select name, age from contactas", as: {String, Int32}
|
# contacts = db.query_all "select name, age from contacts", as: {String, Int32}
|
||||||
# ```
|
# ```
|
||||||
def query_all(query, *args, as types : Tuple)
|
def query_all(query, *args, as types : Tuple)
|
||||||
query_all(query, *args) do |rs|
|
query_all(query, *args) do |rs|
|
||||||
|
@ -190,7 +190,7 @@ module DB
|
||||||
# column's value of each row is read as the given *type*.
|
# column's value of each row is read as the given *type*.
|
||||||
#
|
#
|
||||||
# ```
|
# ```
|
||||||
# names = db.query_all "select name from contactas", as: String
|
# names = db.query_all "select name from contacts", as: String
|
||||||
# ```
|
# ```
|
||||||
def query_all(query, *args, as type : Class)
|
def query_all(query, *args, as type : Class)
|
||||||
query_all(query, *args) do |rs|
|
query_all(query, *args) do |rs|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue