protected function parseSubSelect($query) {
        if ($query instanceof self) {
            $query->columns = [$query->columns[0]];

            return [$query->toSql(), $query->getBindings()];
        } elseif (is_string($query)) {
            return [$query, []];
        } else {
            throw new \InvalidArgumentException();
        }
    }
protected function parseSubSelect($query) {
        if ($query instanceof self) {
            $query->columns = [$query->columns[0]];

            return [$query->toSql(), $query->getBindings()];
        } elseif (is_string($query)) {
            return [$query, []];
        } else {
            throw new \InvalidArgumentException();
        }
    }
protected function parseSubSelect ( $ query ) { if ( $ query instanceof self ) { $ query -> columns = [ $ query -> columns [ 0 ] ] ; return [ $ query -> toSql ( ) , $ query -> getBindings ( ) ] ; } elseif ( is_string ( $ query ) ) { return [ $ query , [ ] ] ; } else { throw new \ InvalidArgumentException ( ) ; } }
Parse the sub-select query into SQL and bindings.

@param  mixed  $query
@return array
Parse the sub - select query into SQL and bindings .