rdblue commented on a change in pull request #1843:
URL: https://github.com/apache/iceberg/pull/1843#discussion_r536931701
##########
File path: spark3/src/main/java/org/apache/iceberg/spark/SparkCatalog.java
##########
@@ -164,13 +183,24 @@ public SparkTable createTable(Identifier ident,
StructType schema,
public StagedTable stageCreate(Identifier ident, StructType schema,
Transform[] transforms,
Map<String, String> properties) throws
TableAlreadyExistsException {
Schema icebergSchema = SparkSchemaUtil.convert(schema);
+ TableIdentifier tableIdentifier = buildIdentifier(ident);
try {
- return new StagedSparkTable(icebergCatalog.newCreateTableTransaction(
- buildIdentifier(ident),
- icebergSchema,
- Spark3Util.toPartitionSpec(icebergSchema, transforms),
- properties.get("location"),
- Spark3Util.rebuildCreateProperties(properties)));
+ Transaction transaction;
+ if (isPathIdentifier(ident)) {
+ transaction = tables.newCreateTableTransaction(
+ tableIdentifier.name(),
Review comment:
This should be `tableIdentifier.location()` right?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]