Coral-Schema alias output upper-cased schema even if I explicitly alias to lower case
rzhang10 opened this issue · 0 comments
rzhang10 commented
To reproduce this issue:
add this test in ViewToAvroSchemaConverterTests
and run it:
@Test
public void foo() {
String viewSql = "CREATE VIEW v AS SELECT id as id FROM basecomplex";
TestUtils.executeCreateViewQuery("default", "v", viewSql);
ViewToAvroSchemaConverter viewToAvroSchemaConverter = ViewToAvroSchemaConverter.create(hiveMetastoreClient);
Schema actualSchema = viewToAvroSchemaConverter.toAvroSchema("default", "v", false, false);
System.out.println(actualSchema);
}
the output will be:
{"type":"record","name":"v","namespace":"default.v","fields":[{"name":"Id","type":"int"}]}
Which shows the column name is Id
rather than the explicit lower-cased alias: id
.