RussellSpitzer commented on code in PR #5409:
URL: https://github.com/apache/iceberg/pull/5409#discussion_r935872067
##########
spark/v3.3/spark/src/test/java/org/apache/iceberg/spark/source/TestSparkDataWrite.java:
##########
@@ -649,6 +650,39 @@ public void testCommitUnknownException() throws
IOException {
Assert.assertEquals("Result rows should match", records, actual);
}
+ @Test
+ public void testWriteWithCaseSensitiveOption() throws IOException {
+ File parent = temp.newFolder(format.toString());
+ File location = new File(parent, "test");
+
+ HadoopTables tables = new HadoopTables(CONF);
+ Table table =
+ tables.create(
+ SCHEMA,
+ PartitionSpec.unpartitioned(),
+ ImmutableMap.of(TableProperties.SPARK_WRITE_ACCEPT_ANY_SCHEMA,
"true"),
+ location.toString());
+
+ List<SimpleRecord1> records = Lists.newArrayList(new SimpleRecord1(1,
"a"));
+ Dataset<Row> dataFrame = spark.createDataFrame(records,
SimpleRecord1.class);
Review Comment:
Instead of making a new class here could we just can do some dataframe games
like
```java
spark.createDataFrame(records, SimpleRecord.class).withColumnRenamed("id",
"Id").withColumnRenamed("data", "DaTa")
```
```
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]