Using Dimension Tables--
How do I create a FACT table in Google Big Query?
example: PK - Dim1_ID FK - Dim2_ID FK - Dim3_ID FK - Dim4_ID FK - Dim5_ID
I need to take the dimensional tables I pulled in from Pentaho into Big Query to do the FACT table.
We tried to create a table as CREATE TABLE Dataset_Fact
But that didnt work.
example:
CREATE TABLE `Dataset.DimModel_FACT` (
DimModel INT PRIMARY KEY,
Dim1_ID INT,
Dim2_ID INT,
Dim3_ID INT,
Dim3_ID INT,
Dim4_ID INT,
Dim5_ID INT,
Dim6_ID INT,
FOREIGN KEY (Dim1_ID) REFERENCES `Dataset.Dim1_ID`(Dim1_ID),
etc