语言

DataFrame.WithColumn(String, Column) 方法

定义

通过添加列或替换同名的现有列来返回新的 DataFrame

public Microsoft.Spark.Sql.DataFrame WithColumn(string colName, Microsoft.Spark.Sql.Column col);
member this.WithColumn : string * Microsoft.Spark.Sql.Column -> Microsoft.Spark.Sql.DataFrame
Public Function WithColumn (colName As String, col As Column) As DataFrame

参数

colName
String

新列的名称

col
Column

新列的列表达式

返回

DataFrame 对象

适用于