You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/12/22 07:29:03 UTC

[GitHub] [spark] HyukjinKwon commented on a diff in pull request #39159: [WIP][SPARK-41666][PYTHON] Support parameterized SQL by PySpark `sql()`

HyukjinKwon commented on code in PR #39159:
URL: https://github.com/apache/spark/pull/39159#discussion_r1055163785


##########
python/pyspark/sql/session.py:
##########
@@ -1376,7 +1376,8 @@ def sql(self, sqlQuery: str, **kwargs: Any) -> DataFrame:
         if len(kwargs) > 0:

Review Comment:
   Another way is to keep the signature same as Scala's. e.g.)
   
   ```python
   def sql(self, sqlQuery: str,  args: Dict[str, str], **kwargs: Any) -> DataFrame:
       # Use args for SQL mapping
   ```



-- 
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: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org