You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@gobblin.apache.org by "arjun4084346 (via GitHub)" <gi...@apache.org> on 2023/06/14 21:45:22 UTC

[GitHub] [gobblin] arjun4084346 commented on a diff in pull request #3705: [GOBBLIN-1843] Utility for detecting non optional unions should convert dataset urn to hive compatible format

arjun4084346 commented on code in PR #3705:
URL: https://github.com/apache/gobblin/pull/3705#discussion_r1230202686


##########
gobblin-iceberg/src/main/java/org/apache/gobblin/iceberg/predicates/DatasetHiveSchemaContainsNonOptionalUnion.java:
##########
@@ -76,7 +76,10 @@ private DbAndTable getDbAndTable(T dataset) {
       throw new IllegalStateException(String.format("Dataset urn [%s] doesn't follow expected pattern. " +
       "Expected pattern = %s", dataset.getUrn(), pattern.pattern()));
     }
-    return new DbAndTable(m.group(1), m.group(2));
+
+    // hive does not use '-' in the table name, so they are replaced with '_'
+    String hiveTableName = m.group(2).replaceAll("-", "_");

Review Comment:
   Let's do `KafkaHiveUtil.getHiveTableName(m.group(2)`



-- 
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: dev-unsubscribe@gobblin.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org