Purpose
The Bronze layer provides:Raw Data Storage
Preserves original data format and structure from source systems
Historical Archive
Maintains a complete history of data as received from sources
Audit Trail
Enables data lineage tracking and compliance requirements
Reprocessing
Allows downstream transformations to be rebuilt from source
Data Sources
The Bronze layer ingests data from two primary source systems:- CRM System
- ERP System
Customer Relationship Management data including:
- Customer information (
cust_info.csv) - Product catalog (
prd_info.csv) - Sales transactions (
sales_details.csv)
Bronze Tables
The Bronze schema contains six tables that mirror the source system structures:CRM Tables
bronze.crm_cust_info
bronze.crm_cust_info
Customer information from the CRM system.Key Fields:
cst_id: Customer identifiercst_key: Customer business keycst_gndr: Gender (raw codes: M/F)cst_marital_status: Marital status (raw codes: S/M)
bronze.crm_prd_info
bronze.crm_prd_info
Product catalog from the CRM system.Key Fields:
prd_id: Product identifierprd_key: Product business key (contains category prefix)prd_line: Product line code (M/R/S/T)prd_start_dt/prd_end_dt: Product validity period
bronze.crm_sales_details
bronze.crm_sales_details
Sales transaction details from the CRM system.
Date fields are stored as integers in YYYYMMDD format and require transformation in the Silver layer.
ERP Tables
bronze.erp_cust_az12
bronze.erp_cust_az12
Customer demographic data from the ERP system.
bronze.erp_loc_a101
bronze.erp_loc_a101
Customer location data from the ERP system.
bronze.erp_px_cat_g1v2
bronze.erp_px_cat_g1v2
Product category and maintenance information.
Loading Process
Data is loaded into Bronze tables using PostgreSQL’sCOPY command for efficient bulk loading:
Loading Procedure
Thebronze.load_bronze() procedure orchestrates the entire Bronze layer data load:
The procedure loads all six tables sequentially, with error handling for each table. If any load fails, the procedure raises an exception with detailed error information.
File Locations
Source files are organized by system:Next Steps
Silver Layer Transformations
Learn how Bronze data is cleansed and standardized in the Silver layer
Related Resources
ETL Procedures
Detailed documentation on ETL orchestration
Gold Layer
Business-ready analytics models