Database Reference
In-Depth Information
12.
Right click the data Flow design surface and choose Execute Task from the context
menu. Visual studio will launch this data flow task with its debugging engine.
13.
when the task is complete, stop Visual studio's debugger and verify that the task ran
successfully; if there are errors, troubleshoot and try again.
14.
open sQl server Management studio and verify that dimTitles has data in it.
Configure the Fill FactTitlesAuthors Data Flow Task
with all the dimension tables filled, it is time to fill the fact tables. it does not matter which one you begin
with, but let's start with the FactTitlesAuthors table.
1.
navigate to the data Flow tab and select the Fill FactTitlesAuthors data Flow Task
from the data Flow Task dropdown box.
2.
Add an olE dB data source to the data flow surface. Rename it to get TitleAuthors
data olE dB destination.
locate the comment -- 2f) Get source data from pubs.dbo .titleauthor in
the sQl code file and review the code beneath it. The code should look like listing
8-7.
3.
Listing 8-7. SQL Code from pubs.dbo.titleauthor
Select
[TitleKey]=DimTitles.TitleKey
--, title_id
,[AuthorKey]=DimAuthors.AuthorKey
--, au_id
,[AuthorOrder]=au_ord
From pubs.dbo.titleauthor
JOIN DWPubsSales.dbo.DimTitles
On pubs.dbo.titleauthor.Title_id=DWPubsSales.dbo.DimTitles.TitleId
JOIN DWPubsSales.dbo.DimAuthors
On pubs.dbo.titleauthor.Au_id=DWPubsSales.dbo.DimAuthors.AuthorId
4.
Edit the olE dB data source to use the dwPubssales connection (similar to Figure
8-23 ).
5.
Click the Preview button to verify that the query worked successfully.
6.
Click the Columns page to force the XMl to be written properly in the .dtsx file.
7.
Close the olE dB source Editor window by clicking the oK button.
8.
Add an olE dB data destination to the data Flow surface. Rename it to Fill
FactTitlesAuthors olE dB destination.
9.
Connect the data Flow Path from the source to the destination.
10.
Edit the olE dB data destination so that it imports data to the FactTitlesAuthors table
(similar to Figure 8-14 ).
11.
Click the Mappings page to force the XMl to be written properly in the .dtsx file and
verify that the mappings look logically correct.
 
Search WWH ::




Custom Search