Die Anfrage
“Create a retail sales gold-layer star schema with dim_date, dim_product, dim_store, dim_customer, and fact_sales tables, the shown keys, attributes, and sales measures, with each fact linked to its date, product, store, and customer dimensions.”
Dann probieren SieAdd a promotion dimension.Add return transactions.
Was diese Zeichnung zeigt
Die dahinterstehenden Entscheidungen verstehen.
01
Use surrogate keys for each dimension to decouple from source systems.
02
Include a transaction_id in the fact table to link back to operational systems.
03
Define relationships with mandatory one-to-many cardinalities from fact to dimensions.
When building a dimensional model for retail sales reporting in a data warehouse or lakehouse environment.