{"push_id":1218065019,"size":1,"distinct_size":1,"ref":"refs/heads/branch-2.0","head":"fcbb7f653df11d923a208c5af03c0a6b9a472376","before":"d226dce12babcd9f30db033417b2b9ce79f44312","commits":[{"sha":"fcbb7f653df11d923a208c5af03c0a6b9a472376","author":{"name":"Cheng Lian","email":"924ffd5d9c6cd2cddca5f635d9a74ad9e1c46f4d@databricks.com"},"message":"[SPARK-16648][SQL] Make ignoreNullsExpr a child expression of First and Last\n\n## What changes were proposed in this pull request?\n\nDefault `TreeNode.withNewChildren` implementation doesn't work for `Last` and when both constructor arguments are the same, e.g.:\n\n```sql\nLAST_VALUE(FALSE) -- The 2nd argument defaults to FALSE\nLAST_VALUE(FALSE, FALSE)\nLAST_VALUE(TRUE, TRUE)\n```\n\nThis is because although `Last` is a unary expression, both of its constructor arguments, `child` and `ignoreNullsExpr`, are `Expression`s. When they have the same value, `TreeNode.withNewChildren` treats both of them as child nodes by mistake. `First` is also affected by this issue in exactly the same way.\n\nThis PR fixes this issue by making `ignoreNullsExpr` a child expression of `First` and `Last`.\n\n## How was this patch tested?\n\nNew test case added in `WindowQuerySuite`.\n\nAuthor: Cheng Lian <lian@databricks.com>\n\nCloses #14295 from liancheng/spark-16648-last-value.\n\n(cherry picked from commit 68b4020d0c0d4f063facfbf4639ef4251dcfda8b)\nSigned-off-by: Wenchen Fan <wenchen@databricks.com>","distinct":true,"url":"https://api.github.com/repos/apache/spark/commits/fcbb7f653df11d923a208c5af03c0a6b9a472376"}]}
{"actor":{"display_login":"asfgit"}}