diff --git a/Command.php b/Command.php index 91f8f2a..2667f2c 100644 --- a/Command.php +++ b/Command.php @@ -181,12 +181,10 @@ class Command extends Component } - if (($execute = $prepare->execute($this->params)) === false) { + if ($prepare->execute($this->params) === false) { throw new Exception('(' . $prepare->errorInfo()[0] . ')' . $prepare->errorInfo()[2]); } - var_dump($execute); - $prepare->closeCursor(); $result = $client->lastInsertId(); diff --git a/SqlBuilder.php b/SqlBuilder.php index f002de8..5992fed 100644 --- a/SqlBuilder.php +++ b/SqlBuilder.php @@ -221,7 +221,7 @@ class SqlBuilder extends Component */ public function all(): string { - return $this->makeSelect($this->query) . ' ' . $this->make() . ' ' . $this->makeLimit(); + return $this->makeSelect($this->query->from) . ' ' . $this->make() . ' ' . $this->makeLimit(); }