Data Ingestion CSV File in Azure Data Bricks




We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


Dataframe_df=spark.read \
.option("header" , True) \
.option("inferschema" , True) \
.csv("/FileStore/dataset/insurance.csv")


We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


type(Dataframe_df)

We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


display(Dataframe_df)

We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


Dataframe_df.show()


We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


Dataframe_df.printSchema()


We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


Dataframe_df.describe().show()


We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


Dataframe_df.createTempView("v_Dataframe_df")


We have a CSV File and we need to create the Data frame with that CSV File , we can use the below python code to create a data frame from a CSV File 


Python Code


%sql
select * from v_Dataframe_df where sex like 'male'


No comments: