stephencelis/SQLite.swift

Numeric Type Column

オープン

#331 opened on 2016/01/19

 (12 件のコメント) (0 件のリアクション) (0 人の担当者)Swift (1,618 件のフォーク)batch import
bughelp wanted

Repository metrics

Stars
 (10,145 個のスター)
PR merge metrics
 (平均マージ 6d 17h) (30d で 4 merged PRs)

説明

update my table.

let x = Expression<Double>("x")

let db = try! Connection(dbFilePath)
let tbl = Table("test")

let dX: Double = 2000
try! db.run(tel.update(x <- dX))

update is success.

but select updated table is failure

for row in try! db.prepare(tbl.select(x)) {
    print(row[x])
}

error occurred.

fatal error: unexpectedly found nil while unwrapping an Optional value

Query.swift  line: 1025
        guard let value = values[idx] as? V.Datatype else { return nil }

please help!

コントリビューターガイド