GitHub user seancxmao opened a pull request:

    https://github.com/apache/spark/pull/22846

    [SPARK-25797][SQL][DOCS] Add migration doc for solving issues caused by 
view canonicalization approach change

    ## What changes were proposed in this pull request?
    Since Spark 2.2, view definitions are stored in a different way from prior 
versions. This may cause Spark unable to read views created by prior versions. 
See [SPARK-25797](https://issues.apache.org/jira/browse/SPARK-25797) for more 
details.
    
    Basically, we have 2 options.
    1) Make Spark 2.2+ able to get older view definitions back. Since the 
expanded text is buggy and unusable, we have to use original text (this is 
possible with 
[SPARK-25459](https://issues.apache.org/jira/browse/SPARK-25459)). However, 
because older Spark versions don't save the context for the database, we cannot 
always get correct view definitions without view default database.
    2) Recreate the views by `ALTER VIEW AS` or `CREATE OR REPLACE VIEW AS`.
    
    This PR aims to add migration doc to help users troubleshoot this issue by 
above option 2.
    
    ## How was this patch tested?
    N/A. 
    
    Docs are generated and checked locally
    
    ```
    cd docs
    SKIP_API=1 jekyll serve --watch
    ```

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/seancxmao/spark SPARK-25797

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/22846.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #22846
    
----
commit a6f4d540d948a887d9dd88b5fc83d3dcf065491f
Author: seancxmao <seancxmao@...>
Date:   2018-10-26T06:08:42Z

    add migration doc

----


---

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

Reply via email to