fetchSet(_:keys:)
Returns a set of records identified by the provided unique keys (primary key or any key with a unique index on it).
static func fetchSet(_ db: Database, keys: [[String : (any DatabaseValueConvertible)?]]) throws -> Set<Self>
Parameters
Returns
A set of records.
Throws
A DatabaseError
whenever an SQLite error occurs.
For example:
try dbQueue.read { db in
let players = try Player.fetchSet(db, keys: [
["email": "a@example.com"],
["email": "b@example.com"]])
}