amaliujia commented on code in PR #40013:
URL: https://github.com/apache/spark/pull/40013#discussion_r1119111599


##########
connector/connect/server/src/main/scala/org/apache/spark/sql/connect/dsl/package.scala:
##########
@@ -703,21 +703,13 @@ package object dsl {
       def drop(columns: String*): Relation = {
         assert(columns.nonEmpty)
 
-        val cols = columns.map(col =>
-          Expression.newBuilder
-            .setUnresolvedAttribute(
-              Expression.UnresolvedAttribute.newBuilder
-                .setUnparsedIdentifier(col)
-                .build())
-            .build())
-
         Relation
           .newBuilder()
           .setDrop(
             Drop
               .newBuilder()
               .setInput(logicalPlan)
-              .addAllCols(cols.asJava)
+              .addAllColumnNames(columns.toSeq.asJava)

Review Comment:
   NVM this is at least as good as before.



-- 
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]

Reply via email to