     /// - throws: A DatabaseError whenever SQLite could not parse the sql query.
     public func updateStatement(sql: String) throws -> UpdateStatement {
         return try UpdateStatement(database: self, sql: sql)
+    }
+    
+    func cachedUpdateStatement(sql: String) throws -> UpdateStatement {
+        if let statement = updateStatementCache[sql] {
+            return statement
+        } else {
+            let statement = try updateStatement(sql)
+            updateStatementCache[sql] = statement
+            return statement
+        }
     }
     
     /// Executes one or several SQL statements, separated by semi-colons.

        return try SelectStatement(database: self, sql: sql)
    }
    
    
    // =========================================================================
    // MARK: - Update Statements

    }
    
    // Cache for columnInfos()
    private func columnInfos(tableName: String) -> [ColumnInfo] {
        if let columnInfos = columnInfosCache[tableName] {
            return columnInfos
        } else {
            let columnInfos = ColumnInfo.fetchAll(self, "PRAGMA table_info(\(tableName.quotedDatabaseIdentifier))")
            columnInfosCache[tableName] = columnInfos
            return columnInfos
