Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Microsoft SQL Server 2008 R2 Master Data Services
  • Table Of Contents Toc
Microsoft SQL Server 2008 R2 Master Data Services

Microsoft SQL Server 2008 R2 Master Data Services

4.3 (4)
close
close
Microsoft SQL Server 2008 R2 Master Data Services

Microsoft SQL Server 2008 R2 Master Data Services

4.3 (4)

Overview of this book

Table of Contents (18 chapters)
close
close
Microsoft SQL Server 2008 R2 Master Data Services
Credits
Foreword
About the Authors
About the Reviewers
www.PacktPub.com
Preface
1
Index

Creating new collections


As we saw in Chapter 4, a collection is a grouping of members that isn't defined by one of the existing attributes. Creating collections is very similar to the process for creating new members. The syntax is exactly the same, other than setting the MemberType_ID to 3, populating the MemberName column with the name of the collection, and populating the MemberCode column with a unique code for the collection. The syntax for this can be seen shortly.

In this example, we are creating a new collection for stores where we want to include a marketing campaign named "2011 Campaign Targets":

/* Create a new collection in the staging tables */
USE MDS -- replace with the name of your master data repository
GO

/* Declare the variables for use in the insert statement */
DECLARE @ModelName nvarchar(50)
DECLARE @EntityName nvarchar(50)

/* Set the variables appropriately */
SET    @ModelName  = 'Store' 
SET    @EntityName  = 'Store'

/* Insert records into the staging table. ...
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Microsoft SQL Server 2008 R2 Master Data Services
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon