/** * Get UpdateQuery builder with pre-populated table name and set of columns to update. Columns * can be scalar values, Parameter objects or even SQLFragments. Call ->run() to perform query. * * @param array $values Initial set of columns associated with values. * @param array $where Initial set of where rules specified as array. * @return UpdateQuery */ public function update(array $values = [], array $where = []) { return $this->database->update($this->name, $values, $where); }
/** * Get UpdateQuery builder with driver specific query compiler. * * @param Database $database Database instance builder should be associated to. * @param array $parameters Initial builder parameters. * @return UpdateQuery */ public function updateBuilder(Database $database, array $parameters = []) { return $this->container->construct(UpdateQuery::class, ['database' => $database, 'compiler' => $this->queryCompiler($database->getPrefix())] + $parameters); }
/** * Generate PDO statement based on generated sql and parameters. * * @return \PDOStatement */ protected function pdoStatement() { return $this->database->statement($this->sqlStatement(), $this->getParameters()); }
/** * {@inheritdoc} */ public function insertBuilder(Database $database, array $parameters = []) { return $this->factory->make(InsertQuery::class, ['database' => $database, 'compiler' => $this->queryCompiler($database->getPrefix())] + $parameters); }