gong commented on code in PR #6979:
URL: https://github.com/apache/inlong/pull/6979#discussion_r1053094557


##########
inlong-sort/sort-connectors/jdbc/src/main/java/org/apache/inlong/sort/jdbc/internal/JdbcMultiBatchingComm.java:
##########
@@ -173,4 +173,26 @@ private static RowData getPrimaryKey(RowData row, 
RowData.FieldGetter[] fieldGet
         return pkRow;
     }
 
+    /**
+     * Get table name From tableIdentifier
+     * tableIdentifier maybe: ${dbName}.${tbName} or 
${dbName}.${schemaName}.${tbName}
+     *
+     * @param tableIdentifier The table identifier for which to get table name.
+     */
+    public static String getTbNameFromIdentifier(String tableIdentifier) {
+        String[] fileArray = tableIdentifier.split("\\.");
+        if (2 == fileArray.length) {
+            return fileArray[1];
+        }
+        if (3 == fileArray.length) {
+            return fileArray[1] + "." + fileArray[2];
+        }
+        return null;
+    }
+
+    public static String getTDbNameFromIdentifier(String tableIdentifier) {

Review Comment:
   method name is similar, I suggest use  full name. 



-- 
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: commits-unsubscr...@inlong.apache.org

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

Reply via email to