public function getStmt()
    {
        // Make sure there are no nested arrays
        if (ArrayUtils::hasAtLeastOneArrayValue($this->bindings)) {
            throw new RuntimeException('PDO bindings can not contain nested arrays');
        }

        // Build target query before bindings are cleared purely for logging purpose
        $log = str_replace(array_keys($this->bindings), array_values($this->bindings), $this->queryBuilder->getQueryString());

        // Execute it
        $stmt = $this->pdo->prepare($this->queryBuilder->getQueryString());
        $stmt->execute($this->bindings);

        // Log target query
        $this->queryLogger->add($log);

        // Clear the buffer
        $this->clear();

        return $stmt;
    }
public function getStmt()
    {
        // Make sure there are no nested arrays
        if (ArrayUtils::hasAtLeastOneArrayValue($this->bindings)) {
            throw new RuntimeException('PDO bindings can not contain nested arrays');
        }

        // Build target query before bindings are cleared purely for logging purpose
        $log = str_replace(array_keys($this->bindings), array_values($this->bindings), $this->queryBuilder->getQueryString());

        // Execute it
        $stmt = $this->pdo->prepare($this->queryBuilder->getQueryString());
        $stmt->execute($this->bindings);

        // Log target query
        $this->queryLogger->add($log);

        // Clear the buffer
        $this->clear();

        return $stmt;
    }
public function getStmt ( ) { // Make sure there are no nested arrays if ( ArrayUtils :: hasAtLeastOneArrayValue ( $ this -> bindings ) ) { throw new RuntimeException ( 'PDO bindings can not contain nested arrays' ) ; } // Build target query before bindings are cleared purely for logging purpose $ log = str_replace ( array_keys ( $ this -> bindings ) , array_values ( $ this -> bindings ) , $ this -> queryBuilder -> getQueryString ( ) ) ; // Execute it $ stmt = $ this -> pdo -> prepare ( $ this -> queryBuilder -> getQueryString ( ) ) ; $ stmt -> execute ( $ this -> bindings ) ; // Log target query $ this -> queryLogger -> add ( $ log ) ; // Clear the buffer $ this -> clear ( ) ; return $ stmt ; }
Returns prepared PDO statement
For internal usage only, regarding its public visibility

@throws \RuntimeException If bindings contain nested arrays
@return \PDOStatement
Returns prepared PDO statement For internal usage only regarding its public visibility