<?xml version="1.0" encoding="utf-8"?>
<html>
  <head>
    <meta http-equiv="X-UA-Compatible" content="IE=8" />
    <link rel="stylesheet" href="../../../css/main.css" type="text/css" />
    <link rel="stylesheet" href="../../../css/jquery.treeview.css" />
    <script src="../../../script/jquery.js" type="text/javascript"></script>
    <script src="../../../script/jquery.cookie.js" type="text/javascript"></script>
    <script src="../../../script/jquery.treeview.js" type="text/javascript"></script>
    <script type="text/javascript">
		                $(document).ready(function(){

		                // first example
		                $("#navigation1").treeview({
			                persist: "location",
			                collapsed: true,
			                unique: true
		                });

		                $("#navigation2").treeview({
			                persist: "location",
			                collapsed: true,
			                unique: true
		                });

		                });
	                </script>
    <title>View</title>
  </head>
  <body>
    <h1>
      <img src="../../../Images/icons/view.png" alt="view icon" /> View: vAdditionalContactInfo</h1>
    <h2>Properties</h2>
    <table id="GetViewList">
      <tr>
        <th>Property</th>
        <th>Value</th>
      </tr>
      <tr>
        <td>Name</td>
        <td>vAdditionalContactInfo</td>
      </tr>
      <tr>
        <td>ID</td>
        <td>1787153412</td>
      </tr>
      <tr>
        <td>Schema</td>
        <td>
          <a href="../../Schemas/Details/Detail_6.html">Person</a>
        </td>
      </tr>
      <tr>
        <td>Owner</td>
        <td>
          <a href="../../Users/Details/Detail_1.html">dbo</a>
        </td>
      </tr>
      <tr>
        <td>Encrypted</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Schema Bound</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>With Check Option</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>ANSI NULLS</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Uses Quoted Identifier</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Has Opaque Metadata</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Published</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Schema Published</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Replicated</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Has Replication Filter</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Has Unchecked Assembly Data</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Date Correlation View</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Uses Database Collation</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Tracked by CDC</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>MS Shipped</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>Modify Date</td>
        <td>8/8/2010 5:23:44 PM</td>
      </tr>
      <tr>
        <td>Create Date</td>
        <td>8/8/2010 5:23:44 PM</td>
      </tr>
    </table>
    <h2>Extended Properties</h2>
    <table>
      <tr>
        <th>Name</th>
        <th>Value</th>
      </tr>
      <tr>
        <td>MS_Description</td>
        <td>Displays the contact name and content from each element in the xml column AdditionalContactInfo for that person.</td>
      </tr>
    </table>
    <h2>View Columns</h2>
    <table>
      <tr>
        <th>Column Name</th>
        <th>Datatype</th>
        <th>Nullable</th>
        <th>Is Identity</th>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_1.html">BusinessEntityID</a>
        </td>
        <td>int</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_2.html">FirstName</a>
        </td>
        <td>Name</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_3.html">MiddleName</a>
        </td>
        <td>Name</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_4.html">LastName</a>
        </td>
        <td>Name</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_5.html">TelephoneNumber</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_6.html">TelephoneSpecialInstructions</a>
        </td>
        <td>nvarchar(max)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_7.html">Street</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_8.html">City</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_9.html">StateProvince</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_10.html">PostalCode</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_11.html">CountryRegion</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_12.html">HomeAddressSpecialInstructions</a>
        </td>
        <td>nvarchar(max)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_13.html">EMailAddress</a>
        </td>
        <td>nvarchar(128)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_14.html">EMailSpecialInstructions</a>
        </td>
        <td>nvarchar(max)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_15.html">EMailTelephoneNumber</a>
        </td>
        <td>nvarchar(50)</td>
        <td>
          <img src="../../../images/icons/true.png" alt="true" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_16.html">rowguid</a>
        </td>
        <td>uniqueidentifier</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
      <tr>
        <td>
          <a href="Columns/Column_1787153412_17.html">ModifiedDate</a>
        </td>
        <td>datetime</td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
        <td>
          <img src="../../../images/icons/false.png" alt="false" class="boolean" />
        </td>
      </tr>
    </table>
    <h2>Indexes</h2>
    <span>No view indexes defined.</span>
    <h2>Object Level Permissions</h2>
    <span>No object level permissions defined.</span>
    <h2>Column Level Permissions</h2>
    <span>No explicit column permissions granted to this object</span>
    <h2>Objects that depend on [vAdditionalContactInfo]</h2>
    <ul id="navigation1">
      <li>
        <a href="../../Views/Details/Detail_1787153412.html">Person.vAdditionalContactInfo</a>
      </li>
    </ul>
    <h2>Objects on which [vAdditionalContactInfo] depends</h2>
    <ul id="navigation2">
      <li>
        <a href="../../Views/Details/Detail_1787153412.html">Person.vAdditionalContactInfo</a>
        <ul>
          <li>
            <a href="../../Tables/Details/Detail_1509580416.html">Person.Person</a>
            <ul>
              <li>
                <a href="../../Datatypes/Details/Detail_260.html">dbo.Name</a>
              </li>
              <li>
                <a href="../../Datatypes/Details/Detail_259.html">dbo.NameStyle</a>
              </li>
              <li>Demographics.exist</li>
              <li>
                <a href="../../XmlSchemaCollections/Details/Detail_65536.html">Person.AdditionalContactInfoSchemaCollection</a>
              </li>
              <li>
                <a href="../../Tables/Details/Detail_341576255.html">Person.BusinessEntity</a>
              </li>
              <li>
                <a href="../../XmlSchemaCollections/Details/Detail_65537.html">Person.IndividualSurveySchemaCollection</a>
              </li>
            </ul>
          </li>
        </ul>
      </li>
    </ul>
    <h2>SQL</h2>
    <table>
      <tr>
        <th>Script</th>
      </tr>
      <tr>
        <td>SET ANSI_NULLS ON<br />SET QUOTED_IDENTIFIER ON<br />CREATE VIEW [Person].[vAdditionalContactInfo] 
AS 
SELECT 
[BusinessEntityID] 
,[FirstName]
,[MiddleName]
,[LastName]
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:telephoneNumber)[1]/act:number', 'nvarchar(50)') AS [TelephoneNumber] 
,LTRIM(RTRIM([ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:telephoneNumber/act:SpecialInstructions/text())[1]', 'nvarchar(max)'))) AS [TelephoneSpecialInstructions] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes";
(act:homePostalAddress/act:Street)[1]', 'nvarchar(50)') AS [Street] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:homePostalAddress/act:City)[1]', 'nvarchar(50)') AS [City] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:homePostalAddress/act:StateProvince)[1]', 'nvarchar(50)') AS [StateProvince] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:homePostalAddress/act:PostalCode)[1]', 'nvarchar(50)') AS [PostalCode] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:homePostalAddress/act:CountryRegion)[1]', 'nvarchar(50)') AS [CountryRegion] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:homePostalAddress/act:SpecialInstructions/text())[1]', 'nvarchar(max)') AS [HomeAddressSpecialInstructions] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:eMail/act:eMailAddress)[1]', 'nvarchar(128)') AS [EMailAddress] 
,LTRIM(RTRIM([ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:eMail/act:SpecialInstructions/text())[1]', 'nvarchar(max)'))) AS [EMailSpecialInstructions] 
,[ContactInfo].ref.value(N'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
declare namespace act="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactTypes"; 
(act:eMail/act:SpecialInstructions/act:telephoneNumber/act:number)[1]', 'nvarchar(50)') AS [EMailTelephoneNumber] 
,[rowguid] 
,[ModifiedDate]
FROM [Person].[Person]
OUTER APPLY [AdditionalContactInfo].nodes(
'declare namespace ci="http://schemas.microsoft.com/sqlserver/2004/07/adventure-works/ContactInfo"; 
/ci:AdditionalContactInfo') AS ContactInfo(ref) 
WHERE [AdditionalContactInfo] IS NOT NULL;
<br />EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'Displays the contact name and content from each element in the xml column AdditionalContactInfo for that person.' , @level0type=N'SCHEMA',@level0name=N'Person', @level1type=N'VIEW',@level1name=N'vAdditionalContactInfo'<br /></td>
      </tr>
    </table>
    <h4 class="seealso">See also</h4>
    <a href="../General.html">List of Views</a>
  </body>
</html>