mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-09-27 01:45:32 +00:00
- Create Dummy Columns on empty import of table columns
This commit is contained in:
parent
7bc48ffd0d
commit
a41dc54667
@ -1309,11 +1309,19 @@ public class TableRepository extends EntityRepository<Table> {
|
|||||||
? ""
|
? ""
|
||||||
: entity.getDomain().getFullyQualifiedName();
|
: entity.getDomain().getFullyQualifiedName();
|
||||||
addField(recordList, domain);
|
addField(recordList, domain);
|
||||||
|
if (!nullOrEmpty(table.getColumns())) {
|
||||||
addRecord(csvFile, recordList, table.getColumns().get(0), false);
|
addRecord(csvFile, recordList, table.getColumns().get(0), false);
|
||||||
|
|
||||||
for (int i = 1; i < entity.getColumns().size(); i++) {
|
for (int i = 1; i < entity.getColumns().size(); i++) {
|
||||||
addRecord(csvFile, new ArrayList<>(), table.getColumns().get(i), true);
|
addRecord(csvFile, new ArrayList<>(), table.getColumns().get(i), true);
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
// Create a dummy Entry for the Column
|
||||||
|
for (int i = 0; i < 9; i++) {
|
||||||
|
addField(recordList, (String) null); // Add empty fields for table information
|
||||||
|
}
|
||||||
|
addRecord(csvFile, recordList);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void addRecord(
|
private void addRecord(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user