Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008)...
Transcript of Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008)...
![Page 1: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/1.jpg)
Data Extracts for everybody A SAS® Customer Intelligence Studio implementation
![Page 2: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/2.jpg)
1. Preparing for SAS® - C.I.S. Building the infrastructure
![Page 3: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/3.jpg)
• Drag-and-drop environment for business to create their own data pulls;
• Design once, deploy multiple times – same DB structure, same workflow, different connection strings (database and user);
• Assign coding to the data on the fly;
Purpose
• Write back to the database;
• Keep implementation under change management;
Solution
SAS® Customer Intelligence 5.4 on SQL Server 2008 R2 databases
![Page 4: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/4.jpg)
SAS® Metadata Folder Structure
• Libraries – all libraries and tables
• Information Maps – all information maps
• Business Contexts – all business contexts
• Stored processes – all stored processes
• Scheduler jobs – all jobs that will be schedule to execute different tasks
Use folders to setup security !
![Page 5: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/5.jpg)
Configure access to external database (SQL Server 2008)
• SQL Server login with appropriate access to the database: DEMO_SAS_User
• SAS® Authentication Domain
• Set the login on a group that contains the users who will access the database • SASUSERS group - all registered users • PUBLIC group - all users (including users
who do not have an individual SAS® identity)
![Page 6: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/6.jpg)
Server definition
![Page 7: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/7.jpg)
Libraries
![Page 8: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/8.jpg)
Information Map
• Presents the data to the user in a familiar manner
• Hides database implementation details, like actual tables and columns names or tables relationships
• Can include calculated fields or/and filters
• Built around one or more “SUBJECT” – different points of view for your analysis
ex. Customer, Household, Account
• Behaviour controlled by “Custom Properties”
• Built using: • SAS® Information Map Studio • PROC INFOMAPS
![Page 9: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/9.jpg)
Information Map – Data Sources and Relationships
![Page 10: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/10.jpg)
Information Map – Custom Properties
![Page 11: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/11.jpg)
Folders in IMAP = Categories in CIS one folder: fields from one or more tables and/or calculated fields
Data Items in IMAP = Data Items in CIS
Information Map – Folders and Data Items
![Page 12: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/12.jpg)
Folder
Numeric Data Item
Character Data Items
Information Map – Folders and Data Items: Custom Properties
![Page 13: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/13.jpg)
Information Map – Metadata definition
![Page 14: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/14.jpg)
Business Context • Is based on an Information Map
• Holds Resources for Customer Intelligence
• Set BC security to control access to Customer Intelligence resources
![Page 15: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/15.jpg)
Stored Processes for use with CIS Process Nodes
• Must use keyword MAUser
• Must deliver result as Package only
![Page 16: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/16.jpg)
Stored Processes for use with CIS Process Nodes
• One code, multiple connection strings: hidden parameter (prompt) that takes connection parameters from a file.
![Page 17: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/17.jpg)
Customer Intelligence Studio We needed “global” variables to transmit values across the entire CIS flow : use Campaign’s Brief.
The “required” variables define the uniqueness of the data pull.
A campaign definition is a template to start from.
Created in SAS Management Console, under Customer Intelligence Plug-In.
A campaign definition is a resource in a business context, and by that is associated with an Information Map.
![Page 18: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/18.jpg)
2. Working with SAS® - C.I.S. Creating a data extract
![Page 19: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/19.jpg)
New Campaign – select the definition you want to use.
• The parameters in Brief are already available;
• If there were parameters with default values, they would be displayed too.
• Must fill at least the required parameters;
• Save the campaign.
SAS® CIS campaign
Everything in CIS is under a SAS Business Context.
![Page 20: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/20.jpg)
SAS® CIS campaign - Counts
All numbers represent DISTINCT Subject IDs !
![Page 21: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/21.jpg)
SAS® CIS campaign - &MATableForMacro
![Page 22: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/22.jpg)
SAS® CIS campaign – Export @Responder level
![Page 23: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/23.jpg)
SAS® CIS campaign – Export @Responder level with duplicates
![Page 24: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/24.jpg)
SAS® CIS campaign – Export @Responder level without duplicates
Cannot pick which records (package code) to keep in the export when duplicates are dropped!
![Page 25: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/25.jpg)
SAS® CIS campaign – Export @ ExportRecords level
Surrogate subject for Export – define it at Information Map level
![Page 26: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/26.jpg)
SAS® CIS campaign – Export @ ExportRecords level
![Page 27: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/27.jpg)
SAS® CIS campaign – Export @ ExportRecords level
5,525 + 5,631 + 3,870 = 15,026 = 15,020 (non-SEEDs) + 2 (SEEDs) x 3 (packages)
![Page 28: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/28.jpg)
• Subject must be “ExportRecords”
• Export definition must be of “ExportRecords” type
![Page 29: Data Extracts for everybody - torsas.ca · Configure access to external database (SQL Server 2008) • SQL Server login with appropriate access to the database: DEMO_SAS_User •](https://reader031.fdocuments.in/reader031/viewer/2022022609/5b93aa5b09d3f2bd1e8bbf3e/html5/thumbnails/29.jpg)
Gabriela Nanau Email: [email protected] CORNERSTONE Web: www.cstonecanada.com