Apache Spark SQL: CTAS USING CSV with specific delimiter
Mike Houngbadji

Mike Houngbadji @mikekenneth77

About: Hi, just a problem solver, I use mainly Python. Working in Data Engineering & Analytics, though still connected to the web/apps dev community.

Location:
World
Joined:
Mar 22, 2019

Apache Spark SQL: CTAS USING CSV with specific delimiter

Publish Date: Nov 16 '22
3 0

To use CTAS (Create table as Select) in Apache Spark with a specific delimiter using the OPTION syntax:

CREATE TABLE sample_table
USING CSV
OPTIONS ('delimiter'='|')
AS
SELECT ....
Enter fullscreen mode Exit fullscreen mode

SparkSQL Documentation

PS:
I wrote this to also help myself retrieve the solution faster.

Comments 0 total

    Add comment