rahil-c commented on code in PR #18488:
URL: https://github.com/apache/hudi/pull/18488#discussion_r3067187064
##########
hudi-spark-datasource/hudi-spark3.3.x/src/main/scala/org/apache/spark/sql/parser/HoodieSpark3_3ExtendedSqlAstBuilder.scala:
##########
@@ -2702,8 +2717,13 @@ class HoodieSpark3_3ExtendedSqlAstBuilder(conf: SQLConf,
delegate: ParserInterfa
private def addMetadataForType(dataType:
HoodieSqlBaseParser.DataTypeContext, builder: MetadataBuilder): Unit = {
val typeText = dataType.getText
- if (typeText.equalsIgnoreCase(HoodieSchemaType.BLOB.name())) {
+ val upperTypeText = typeText.toUpperCase(Locale.ROOT)
+ if (upperTypeText == HoodieSchemaType.BLOB.name()) {
builder.putString(HoodieSchema.TYPE_METADATA_FIELD,
HoodieSchemaType.BLOB.name())
+ } else if (upperTypeText.startsWith("VECTOR(")) {
Review Comment:
Im wondering if there is any other way we can match here, what are the
values of typeText, and upperTypeText typically? Is there room to leverage the
HoodieSchema.parseTypeDescriptor for this?
--
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]