Google News
logo
PySpark - Quiz(MCQ)
Which of the following is used to write data to a Parquet file in PySpark?
A)
write.csv()
B)
write.parquet()
C)
write.json()
D)
write.text()

Correct Answer :   write.parquet()


Explanation : write.parquet() is used to write data to a Parquet file in PySpark. Parquet is a columnar storage format that is optimized for query performance. Other file input/output operations in PySpark include write.csv(), write.json(), and write.text().

Advertisement