Created
January 16, 2022 23:03
-
-
Save RachidAZ/472e442bd3c40c11f63d5cc1bb6b4a0b to your computer and use it in GitHub Desktop.
DateFrame <--> View in PySpark
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# create DF from Table/View: | |
df=spark.sql("select * from {table_view_name}") | |
#create View from DF: | |
df.createOrReplaceTempView("{view_name}") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment