Overview
Themetadb.base_table table stores information about all tables that are extracted from data sources or transformed from those tables. This is a system metadata table that tracks the lineage and source of each table in your Metadb instance.
Schema
The schema name where the base table resides
The name of the base table
The name of the data source this table was extracted from (as defined in
create data source)true if this table is a transformed table (created via data mapping), false if it’s extracted directly from a sourceSchema name of the parent table (only populated if
transformed is true)Table name of the parent table (only populated if
transformed is true)Usage
Query All Base Tables
Example Output
Use Cases
Find Tables from a Data Source
Find Tables from a Data Source
List all tables extracted from a specific data source:
Track Transformed Tables
Track Transformed Tables
Find all tables that were created through data transformation:
Table Lineage
Table Lineage
Understand the complete lineage of a table including its source and any parent relationships:
Count Tables by Source
Count Tables by Source
Get a summary of how many tables come from each data source:
Understanding Table Types
Main tables end with double underscores (e.g.,
patron__) and contain historical records. The corresponding current table (e.g., patron) contains only current records where __current = true.Transformed Tables
When you create data mappings to transform JSON or other data, Metadb creates new tables and records them inmetadb.base_table with:
transformed = trueparent_schema_nameandparent_table_namepointing to the source tablesource_nameinherited from the parent table
library.inventory_metadata which will be tracked as a transformed table.
Related Resources
metadb.table_update
Track when tables were last updated
Data Sources
Define data sources that populate these tables
Data Mappings
Create transformed tables from JSON data
metadb.log
View system logs and events
