You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add STRUCT/ARRAY/MAP nested column support to RAB (CSA-371)
Expands complex SQL types (STRUCT, ARRAY<STRUCT>, MAP<K,STRUCT>) into
child Column assets linked via parentColumn hierarchy. Sub-columns are
excluded from the table's flat Columns list by clearing all
tableQualifiedName/tableName/table/view refs — navigation is via
parentColumn chain only.
New fields on sub-columns:
- parentColumnQualifiedName / parentColumn / parentColumnName
- columnHierarchy: newline-delimited JSON ancestor entries (enables
breadcrumb display in the UI, e.g. struct_col > city)
- columnDepthLevel: 1 for direct fields, 2+ for deeper nesting
- nestedColumnOrder: ordinal position within parent
- subType=nested
QN format (matching Databricks connector):
- STRUCT field: tableQN/parentCol/fieldName
- ARRAY<STRUCT>: tableQN/parentCol/items/fieldName
- MAP<K,STRUCT>: tableQN/parentCol/values/fieldName
- Deeply nested: tableQN/parentCol/outer/inner
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: bladata1990 <balakrishnan.r@atlan.com>
val parentQN ="$connectionQN/${details.parentPartialQN}"
68
74
val rawDataType = trimWhitespace(inputRow.getOrElse(Column.DATA_TYPE.atlanFieldName) { "" })
75
+
val displayDataType = baseTypeName(rawDataType)
69
76
var precision:Int?=null
70
77
var scale:Double?=null
71
78
var maxLength:Long?=null
@@ -95,6 +102,7 @@ class ColumnXformer(
95
102
RowSerde.getHeaderForField(Column.VIEW_QUALIFIED_NAME, Column::class.java) to if (details.viewPQN.isNotBlank()) "$connectionQN/${details.viewPQN}"else"",
96
103
RowSerde.getHeaderForField(Column.VIEW, Column::class.java) to if (details.parentTypeName ==View.TYPE_NAME) "${details.parentTypeName}@$parentQN"else"",
97
104
RowSerde.getHeaderForField(Column.MATERIALIZED_VIEW, Column::class.java) to if (details.parentTypeName ==MaterializedView.TYPE_NAME) "${details.parentTypeName}@$parentQN"else"",
105
+
RowSerde.getHeaderForField(Column.DATA_TYPE, Column::class.java) to displayDataType,
98
106
RowSerde.getHeaderForField(Column.ORDER, Column::class.java) to inputRow.getOrElse(Column.ORDER.atlanFieldName) { "" },
99
107
RowSerde.getHeaderForField(Column.RAW_DATA_TYPE_DEFINITION, Column::class.java) to rawDataType,
100
108
RowSerde.getHeaderForField(Column.PRECISION, Column::class.java) to (precision?.toString() ?:""),
@@ -106,6 +114,116 @@ class ColumnXformer(
106
114
}
107
115
}
108
116
117
+
/** Returns the base type name, stripping any angle-bracket type parameters.
118
+
* E.g. "STRUCT<a:INT,b:DOUBLE>" → "STRUCT", "INT" → "INT". */
0 commit comments