amaliujia commented on code in PR #38587:
URL: https://github.com/apache/spark/pull/38587#discussion_r1018579606
##########
connector/connect/src/main/protobuf/spark/connect/relations.proto:
##########
@@ -280,9 +280,22 @@ message RenameColumns {
// Required. The input relation.
Relation input = 1;
- // Required.
+ // Optional.
//
// The number of columns of the input relation must be equal to the length
// of this field. If this is not true, an exception will be returned.
+ //
+ // This field does not co-exist with the field `rename_columns_map`.
Review Comment:
Example:
```
message RenameColumns {
ENUM {
toDF;
RenameColumnByNames;
RenameColumnByExpressions;
}
Enum type;
field1_used_by_toDF;
field2_used_by_RenameColumnByNames;
field3_used_by_RenameColumnByExpressions;
}
```
Then based on the enum value we just fetch the corresponding fields?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]