public function addAliasedRawColumn(string $alias, string $column)
    {
        $table = $this->getTable();

        if (!$table->hasColumn($column)) {
            throw InvalidArgumentException::format(
                    'Invalid column for select: must be one of (%s), \'%s\' given',
                    Debug::formatValues($table->getColumnNames()), $column
            );
        }

        $this->aliasColumnMap[$alias] = Expr::column($this->getTableAlias(), $table->findColumn($column));

        return $this;
    }
public function addAliasedRawColumn(string $alias, string $column)
    {
        $table = $this->getTable();

        if (!$table->hasColumn($column)) {
            throw InvalidArgumentException::format(
                    'Invalid column for select: must be one of (%s), \'%s\' given',
                    Debug::formatValues($table->getColumnNames()), $column
            );
        }

        $this->aliasColumnMap[$alias] = Expr::column($this->getTableAlias(), $table->findColumn($column));

        return $this;
    }
public function addAliasedRawColumn ( string $ alias , string $ column ) { $ table = $ this -> getTable ( ) ; if ( ! $ table -> hasColumn ( $ column ) ) { throw InvalidArgumentException :: format ( 'Invalid column for select: must be one of (%s), \'%s\' given' , Debug :: formatValues ( $ table -> getColumnNames ( ) ) , $ column ) ; } $ this -> aliasColumnMap [ $ alias ] = Expr :: column ( $ this -> getTableAlias ( ) , $ table -> findColumn ( $ column ) ) ; return $ this ; }
Adds a column from the FROM table.

@param string $alias
@param string $column

@return static
@throws InvalidArgumentException
Adds a column from the FROM table .