mirror of
https://github.com/groue/GRDB.swift
synced 2026-11-24 04:07:47 +00:00
24 lines
635 B
Swift
24 lines
635 B
Swift
//
|
|
// UpdateStatement.swift
|
|
// GRDB
|
|
//
|
|
// Created by Gwendal Roué on 30/06/2015.
|
|
// Copyright © 2015 Gwendal Roué. All rights reserved.
|
|
//
|
|
|
|
public final class UpdateStatement : Statement {
|
|
public func execute() throws {
|
|
if database.configuration.verbose {
|
|
NSLog("%@", sql)
|
|
}
|
|
let code = sqlite3_step(sqliteStatement)
|
|
switch code {
|
|
case SQLITE_DONE:
|
|
// the statement has finished executing successfully
|
|
break
|
|
default:
|
|
try SQLiteError.checkCResultCode(code, sqliteConnection: database.sqliteConnection, sql: sql)
|
|
}
|
|
}
|
|
}
|