| Property | Value |
|---|---|
| Name | vVendorWithContacts |
| ID | 2075154438 |
| Schema | Purchasing |
| Owner | dbo |
| Encrypted |
|
| Schema Bound |
|
| With Check Option |
|
| ANSI NULLS |
|
| Uses Quoted Identifier |
|
| Has Opaque Metadata |
|
| Published |
|
| Schema Published |
|
| Replicated |
|
| Has Replication Filter |
|
| Has Unchecked Assembly Data |
|
| Date Correlation View |
|
| Uses Database Collation |
|
| Tracked by CDC |
|
| MS Shipped |
|
| Modify Date | 8/8/2010 5:23:46 PM |
| Create Date | 8/8/2010 5:23:46 PM |
| Name | Value |
|---|---|
| MS_Description | Vendor (company) names and the names of vendor employees to contact. |
| Column Name | Datatype | Nullable | Is Identity |
|---|---|---|---|
| BusinessEntityID | int |
|
|
| Name | Name |
|
|
| ContactType | Name |
|
|
| Title | nvarchar(8) |
|
|
| FirstName | Name |
|
|
| MiddleName | Name |
|
|
| LastName | Name |
|
|
| Suffix | nvarchar(10) |
|
|
| PhoneNumber | Phone |
|
|
| PhoneNumberType | Name |
|
|
| EmailAddress | nvarchar(50) |
|
|
| EmailPromotion | int |
|
|
| Script |
|---|
| SET ANSI_NULLS ON SET QUOTED_IDENTIFIER ON CREATE VIEW [Purchasing].[vVendorWithContacts] AS SELECT v.[BusinessEntityID] ,v.[Name] ,ct.[Name] AS [ContactType] ,p.[Title] ,p.[FirstName] ,p.[MiddleName] ,p.[LastName] ,p.[Suffix] ,pp.[PhoneNumber] ,pnt.[Name] AS [PhoneNumberType] ,ea.[EmailAddress] ,p.[EmailPromotion] FROM [Purchasing].[Vendor] v INNER JOIN [Person].[BusinessEntityContact] bec ON bec.[BusinessEntityID] = v.[BusinessEntityID] INNER JOIN [Person].ContactType ct ON ct.[ContactTypeID] = bec.[ContactTypeID] INNER JOIN [Person].[Person] p ON p.[BusinessEntityID] = bec.[PersonID] LEFT OUTER JOIN [Person].[EmailAddress] ea ON ea.[BusinessEntityID] = p.[BusinessEntityID] LEFT OUTER JOIN [Person].[PersonPhone] pp ON pp.[BusinessEntityID] = p.[BusinessEntityID] LEFT OUTER JOIN [Person].[PhoneNumberType] pnt ON pnt.[PhoneNumberTypeID] = pp.[PhoneNumberTypeID]; EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Vendor (company) names and the names of vendor employees to contact.' , @level0type=N'SCHEMA',@level0name=N'Purchasing', @level1type=N'VIEW',@level1name=N'vVendorWithContacts' |