$stmt->execute($params);
return $stmt;
}
+
+ function insert($table, $row)
+ {
+ $sql = sprintf('INSERT INTO %s (%s) VALUES (%s)',
+ '"'.$table.'"',
+ implode(', ', array_keys($row)),
+ implode(', ', array_fill(0, count($row), '?'))
+ );
+ return $this->query($sql, array_values($row));
+ }
}