[FIXED] Spark SQL for Databricks - extraneous input ')' expecting [...]

Issue

i'm copy/pasting a tutorial and trying to understand what's going on behind it, this one looked fairly straight forward, but for some reason it doesn't work. It seems to take issue with the closing parenthesis around the column name when doing a Partitioned By. I've tried removing the brackets, restructuring the query, checking there are no weird characters in notepad++, etc. What's gone wrong here?

Screenshot showing the error


Solution

Missing a USING clause, e.g.

CREATE TABLE rectangles
  USING PARQUET
  PARTITIONED BY (width)
  CLUSTERED BY (length) INTO 8 buckets
  AS SELECT * FROM boxes


Answered By - thebluephantom
Answer Checked By - Katrina (sql.easybugfix Volunteer)

Related Posts

Post a Comment