Skip to content

[SPARK-22581][SQL] Catalog api does not allow to specify partitioning columns with create(external)table#19796

Closed
timvw wants to merge 4 commits intoapache:masterfrom
timvw:master
Closed

[SPARK-22581][SQL] Catalog api does not allow to specify partitioning columns with create(external)table#19796
timvw wants to merge 4 commits intoapache:masterfrom
timvw:master

Conversation

@timvw
Copy link
Contributor

@timvw timvw commented Nov 22, 2017

What changes were proposed in this pull request?

Enhance Catalog api such that partition columns can be specified on createTable method

How was this patch tested?

Added a test to verify that the created table indeed has added a partition column

@AmplabJenkins
Copy link

Can one of the admins verify this patch?

test("createTable with partition columns", Tag("go")) {
withTable("t") {
withTempDir { dir =>
spark.catalog.createTable(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May be you need spark.sessionState.catalog.createTable?

source: String,
schema: StructType,
options: Map[String, String],
partitionColumnNames : Seq[String]): DataFrame
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we will not introduce a new API for partitioning columns in the current stage. Let us use SQL DDL for creating the table.

Copy link
Contributor Author

@timvw timvw Nov 7, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Imho, having an API without options to specify partitioning in a big-data context is just pointless.

=> When looking at https://docs.google.com/document/d/1zLFiA1VuaWeVxeTDXNg8bL6GP3BVoOZBkewFtEnjEoo/edit# I get the feeling that API changes are coming, just not in the current stage. Fine with me.

@timvw timvw closed this Nov 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants