I have a dimensions table invoices and a fact table
I can see my invoices in dimension invoice but it won't show up in the Fact table. The Fact table is connected to the dimensions table invoice with a foreign key invoice_id. But it's still not showing me the invoice
How can I fix this problem? Can someone help?
Thank you
SELECT [Id] ,[Land] ,[Firm] ,[Magazijn] ,[year] ,[Invoice number] ,[Checksum] ,[LastModifiedDate]
FROM [DataWarehouse].[dbo].[Dim_Invoices]
where Invoice number = 6451847
Here is get no invoice for this number
SELECT [Id] ,[Invoice_id],[Land] ,[Firm] ,[Magazijn] ,[year] ,[Invoice number] ,[Invoice_Date] ,[LastModifiedDate]
FROM [DataWarehouse].[dbo].[FACT]
where Invoice number = 6451847
Here it shows the invoice number (note Invoice_ID is the FK)
1条答案
按热度按时间pdtvr36n1#
You need to try something like this:
I am not sure why you have the fields in the fact table that you do as they are duplicated in the dimension. What are your measures?