Database Reference
In-Depth Information
Figure 8-17. Locating the create DWPubsSales script
2.
open this file and execute its code in either Visual studio or sQl server
Management studio to re-create the database.
You can do this by right-clicking an area in the sQl code window to bring up the context menu and select
Execute sQl. if the Connect to database Engine dialog box appears, type in your server name and click the
Connect button. in a few seconds, you should receive a message stating “The dwPubssales data warehouse
is now created.”
Fill Dimauthors Data Flow task
now that you located the ETl code, you need to use it in the task that fills dimAuthors. This is the same
process we used in Chapter 7.
1.
open the PublicationindustriesETlCode.sql sQl script file in Visual studio or sQl
server Management studio (Figure 8-17 ) and locate the code that is commented as
-- Step 2 Code used to fill tables .
2.
navigate to the data Flow tab and select Fill dimAuthors data Flow Task from the
data Flow Task dropdown box.
3.
Add an olE dB data source to the data flow surface. Rename it to get Authors data
olE dB source.
locate the comment -- Step 2a) Get source data from pubs.dbo.
authors in the sQl code file and review the code beneath it. The code should look
like listing 8-1.
Listing 8-1. SQL Code from pubs.dbo.authors
4.
Select
[AuthorId]=Cast( au_id as nChar(11) )
 
Search WWH ::




Custom Search