You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Apache Spark (Jira)" <ji...@apache.org> on 2021/07/27 21:46:00 UTC

[jira] [Commented] (SPARK-36310) Fix hasnan() window function in IndexOpsMixin

    [ https://issues.apache.org/jira/browse/SPARK-36310?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17388312#comment-17388312 ] 

Apache Spark commented on SPARK-36310:
--------------------------------------

User 'ueshin' has created a pull request for this issue:
https://github.com/apache/spark/pull/33547

> Fix hasnan() window function in IndexOpsMixin
> ---------------------------------------------
>
>                 Key: SPARK-36310
>                 URL: https://issues.apache.org/jira/browse/SPARK-36310
>             Project: Spark
>          Issue Type: Bug
>          Components: PySpark
>    Affects Versions: 3.2.0
>            Reporter: Xinrong Meng
>            Priority: Major
>
>  
> {code:java}
> File "/__w/spark/spark/python/pyspark/pandas/groupby.py", line 1497, in pyspark.pandas.groupby.GroupBy.rank
> Failed example:
>     df.groupby("a").rank().sort_index()
> Exception raised:
> ...
> pyspark.sql.utils.AnalysisException: It is not allowed to use a window function inside an aggregate function. Please use the inner window function in a sub-query.
> {code}
> As shown above, hasnans() used in "rank" causes "It is not allowed to use a window function inside an aggregate function" exception.
> We shall adjust that.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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