es/Microsoft.SqlServer.Management.PSProvider.dll-Help.xml

<?xml version="1.0" encoding="UTF-8"?>
 
<helpItems schema="maml">
 
<!-- v 1.3.0.36 -->
<command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10">
    <command:details>
        <command:name>
                   Decode-SqlName
        </command:name>
        <maml:description>
            <maml:para>Devuelve el identificador de SQL Server original cuando se da un identificador que se ha codificado en un formato que se puede usar en las rutas de acceso de PowerShell.</maml:para>
        </maml:description>
        <maml:copyright>
            <maml:para></maml:para>
        </maml:copyright>
        <command:verb>Decode</command:verb>
        <command:noun>SqlName</command:noun>
        <dev:version></dev:version>
    </command:details>
    <maml:description>
        <maml:para>Devuelve el identificador de SQL Server sin codificar cuando se da un identificador que se ha codificado en un formato que se puede usar en las rutas de acceso de PowerShell. Los identificadores delimitados de SQL Server pueden contener caracteres especiales que normalmente no se admiten en los nombres de objeto de PowerShell. Estos caracteres extendidos deben codificarse con su representación hexadecimal o eludirse con el carácter de comilla ( ` ). En el caso de ciertos caracteres, como el carácter de dos puntos ( : ), no se puede hacer que se eludan. La codificación hexadecimal está en el formato %nn. Decode-SqlName convierte las siguientes codificaciones a los caracteres correspondientes: %5C-\ %3A-: %2E-. %2F-/ %25-% %3C-&lt; %3E-&gt; %2A-* %3F-? %5B-[ %5D-] %7C-|</maml:para>
    </maml:description>
    <!-- Cmdlet syntax section-->
    <command:syntax>
        <command:syntaxItem>
            <maml:name>Decode-SqlName</maml:name>
            <command:parameter required="true" variableLength="false" globbing="false" pipelineInput="true (ByValue, ByPropertyName)" position="2">
                <maml:name>SqlName</maml:name>
                <maml:description>
                    <maml:para>El identificador de SQL Server cuyo formato se va a cambiar.</maml:para>
                </maml:description>
                <command:parameterValue required="true" variableLength="false">string</command:parameterValue>
            </command:parameter>
        </command:syntaxItem>
    </command:syntax>
    <!-- Cmdlet parameter section -->
    <command:parameters>
        <command:parameter required="true" variableLength="false" globbing="false" pipelineInput="true (ByValue, ByPropertyName)" position="2">
            <maml:name>SqlName</maml:name>
            <maml:description>
                <maml:para>El identificador de SQL Server cuyo formato se va a cambiar.</maml:para>
                                 
            </maml:description>
            <command:parameterValue required="true" variableLength="false">string</command:parameterValue>
            <dev:type>
                <maml:name>string</maml:name>
                <maml:uri/>
            </dev:type>
            <dev:defaultValue></dev:defaultValue>
        </command:parameter>
    </command:parameters>
    <!-- Input - Output section-->
    <command:inputTypes>
        <command:inputType>
            <dev:type>
                <maml:name>String</maml:name>
                <maml:uri/>
                <maml:description />
            </dev:type>
            <maml:description>
                <maml:para>
                    <!-- description -->
                     
                </maml:para>
            </maml:description>
        </command:inputType>
    </command:inputTypes>
    <command:returnValues>
        <command:returnValue>
            <dev:type>
                <maml:name>String</maml:name>
                <maml:uri />
                <maml:description />
            </dev:type>
            <maml:description>
                <maml:para>
                    <!-- description -->
                     
                </maml:para>
            </maml:description>
        </command:returnValue>
    </command:returnValues>
    <!-- Error section-->
    <command:terminatingErrors />
    <command:nonTerminatingErrors />
        <!-- Notes section -->
    <maml:alertSet>
        <maml:title></maml:title>
        <maml:alert>
            <maml:para>
                           
                        </maml:para>
        </maml:alert>
        <maml:alert>
            <maml:para></maml:para>
        </maml:alert>
    </maml:alertSet>
     <!-- Example section -->
    <command:examples>
 
        <command:example>
            <maml:title>
                -------------------------- EXAMPLE 1 --------------------------
            </maml:title>
            <maml:introduction>
                <maml:para>C:\PS&gt;</maml:para>
            </maml:introduction>
              <dev:code>
Decode-SqlName -SqlName &quot;My%3ATable`/&quot;
 
My:Table/ </dev:code>
                   <dev:remarks>
                                <maml:para>Descripción</maml:para>
                                <maml:para>-----------</maml:para>
                      <maml:para>Descodificar un identificador de SQL Server que tiene una representación hexadecimal codificada del carácter dos puntos ( : ). PowerShell también quita el carácter de comilla invertida ( ` ) de una carácter que se elude /.</maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
              </dev:remarks>
            <command:commandLines>
                <command:commandLine>
                    <command:commandText></command:commandText>
                </command:commandLine>
            </command:commandLines>
        </command:example>
    </command:examples>
    <!-- Link section -->
    <maml:relatedLinks>
        <maml:navigationLink>
            <maml:linkText>SQL Server Books Online: Using SQL Server Identifiers in PowerShell</maml:linkText>
            <maml:uri/>
        </maml:navigationLink>
        <maml:navigationLink>
            <maml:linkText>Encode-SqlName</maml:linkText>
            <maml:uri/>
        </maml:navigationLink>
    </maml:relatedLinks>
</command:command>
 
<!-- v 1.3.0.36 -->
<command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10">
    <command:details>
        <command:name>
                   Encode-SqlName
        </command:name>
        <maml:description>
            <maml:para>Codifica los caracteres extendidos en los nombres de SQL Server para los formatos que se pueden usar en las rutas de acceso de PowerShell.</maml:para>
        </maml:description>
        <maml:copyright>
            <maml:para></maml:para>
        </maml:copyright>
        <command:verb>Encode</command:verb>
        <command:noun>SqlName</command:noun>
        <dev:version></dev:version>
    </command:details>
    <maml:description>
        <maml:para>Codifica los caracteres especiales en los nombres de SQL Server para los formatos que se pueden usar en las rutas de acceso de PowerShell. Los identificadores delimitados de SQL Server pueden contener caracteres que normalmente no se admiten en los nombres de objeto de PowerShell. Al usar identificadores delimitados en las rutas de acceso del proveedor de SQL Server, estos caracteres extendidos debe codificarse en su representación hexadecimal o eludirse con el carácter `. En el caso de ciertos caracteres, como el carácter de dos puntos (:), no se puede hacer que se eludan. La codificación hexadecimal para los caracteres está en el formato %nn. Los caracteres codificados mediante Encode-SqlName son: \:./%&lt;&gt;*?[]|</maml:para>
    </maml:description>
    <!-- Cmdlet syntax section-->
    <command:syntax>
        <command:syntaxItem>
            <maml:name>Encode-SqlName</maml:name>
            <command:parameter required="true" variableLength="false" globbing="false" pipelineInput="true (ByValue, ByPropertyName)" position="2">
                <maml:name>SqlName</maml:name>
                <maml:description>
                    <maml:para>El identificador de SQL Server que se va a codificar.</maml:para>
                </maml:description>
                <command:parameterValue required="true" variableLength="false">string</command:parameterValue>
            </command:parameter>
        </command:syntaxItem>
    </command:syntax>
    <!-- Cmdlet parameter section -->
    <command:parameters>
        <command:parameter required="true" variableLength="false" globbing="false" pipelineInput="true (ByValue, ByPropertyName)" position="2">
            <maml:name>SqlName</maml:name>
            <maml:description>
                <maml:para>El identificador de SQL Server que se va a codificar.</maml:para>
                                 
            </maml:description>
            <command:parameterValue required="true" variableLength="false">string</command:parameterValue>
            <dev:type>
                <maml:name>string</maml:name>
                <maml:uri/>
            </dev:type>
            <dev:defaultValue></dev:defaultValue>
        </command:parameter>
    </command:parameters>
    <!-- Input - Output section-->
    <command:inputTypes>
        <command:inputType>
            <dev:type>
                <maml:name>String</maml:name>
                <maml:uri/>
                <maml:description />
            </dev:type>
            <maml:description>
                <maml:para>
                    <!-- description -->
                     
                </maml:para>
            </maml:description>
        </command:inputType>
    </command:inputTypes>
    <command:returnValues>
        <command:returnValue>
            <dev:type>
                <maml:name>String</maml:name>
                <maml:uri />
                <maml:description />
            </dev:type>
            <maml:description>
                <maml:para>
                    <!-- description -->
                     
                </maml:para>
            </maml:description>
        </command:returnValue>
    </command:returnValues>
    <!-- Error section-->
    <command:terminatingErrors />
    <command:nonTerminatingErrors />
        <!-- Notes section -->
    <maml:alertSet>
        <maml:title></maml:title>
        <maml:alert>
            <maml:para>
                           
                        </maml:para>
        </maml:alert>
        <maml:alert>
            <maml:para></maml:para>
        </maml:alert>
    </maml:alertSet>
     <!-- Example section -->
    <command:examples>
 
        <command:example>
            <maml:title>
                -------------------------- EXAMPLE 1 --------------------------
            </maml:title>
            <maml:introduction>
                <maml:para>C:\PS&gt;</maml:para>
            </maml:introduction>
              <dev:code>
Encode-SqlName -SqlName &quot;My:Table/&quot;
 
My%3ATable%2F </dev:code>
                   <dev:remarks>
                                <maml:para>Descripción</maml:para>
                                <maml:para>-----------</maml:para>
                      <maml:para>Codifica un nombre de tabla de SQL Server que contenga los caracteres : y /.</maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
              </dev:remarks>
            <command:commandLines>
                <command:commandLine>
                    <command:commandText></command:commandText>
                </command:commandLine>
            </command:commandLines>
        </command:example>
    </command:examples>
    <!-- Link section -->
    <maml:relatedLinks>
        <maml:navigationLink>
            <maml:linkText>SQL Server Books Online: Using SQL Server Identifiers in PowerShell</maml:linkText>
            <maml:uri/>
        </maml:navigationLink>
        <maml:navigationLink>
            <maml:linkText>Decode-SqlName</maml:linkText>
            <maml:uri/>
        </maml:navigationLink>
    </maml:relatedLinks>
</command:command>
 
<!-- v 1.3.0.36 -->
<command:command xmlns:maml="http://schemas.microsoft.com/maml/2004/10" xmlns:command="http://schemas.microsoft.com/maml/dev/command/2004/10" xmlns:dev="http://schemas.microsoft.com/maml/dev/2004/10">
    <command:details>
        <command:name>
                   Convert-UrnToPath
        </command:name>
        <maml:description>
            <maml:para>Convierte un URN de Objetos de administración de SQL Server en una ruta de acceso de proveedor de SQL Server PowerShell.</maml:para>
        </maml:description>
        <maml:copyright>
            <maml:para></maml:para>
        </maml:copyright>
        <command:verb>Convert</command:verb>
        <command:noun>UrnToPath</command:noun>
        <dev:version></dev:version>
    </command:details>
    <maml:description>
        <maml:para>Convierte un nombre de recursos uniforme (URN) de Objetos de administración de SQL Server en una ruta de acceso del proveedor de SQL Server. Los Objetos de administración de SQL Server tienen una propiedad Urn que devuelve una cadena que indica su ubicación en la jerarquía de objetos de SQL Server. Si los nodos del Urn son identificadores delimitados de SQL Server que contienen caracteres extendidos que no se admiten en los nodos de ruta de acceso de PowerShell, los caracteres extendidos se codifican con su representación hexadecimal. Por ejemplo, un nombre de tabla &quot;Mi:Tabla&quot; se codifica como &quot;Mi%3ATabla&quot;.</maml:para>
    </maml:description>
    <!-- Cmdlet syntax section-->
    <command:syntax>
        <command:syntaxItem>
            <maml:name>Convert-UrnToPath</maml:name>
            <command:parameter required="true" variableLength="false" globbing="false" pipelineInput="true (ByValue, ByPropertyName)" position="named">
                <maml:name>Urn</maml:name>
                <maml:description>
                    <maml:para>Cadena de caracteres que contiene un nombre de recurso único (URN) de SQL Server. Un URN de SQL Server es una cadena que identifica la ubicación de un objeto en la jerarquía de SQL Server. Los URN tienen la misma información que una ruta de acceso de SQL Server PowerShell pero en un formato diferente. Los Objetos de administración de SQL Server tienen una propiedad Urn.</maml:para>
                </maml:description>
                <command:parameterValue required="true" variableLength="false">string</command:parameterValue>
            </command:parameter>
        </command:syntaxItem>
    </command:syntax>
    <!-- Cmdlet parameter section -->
    <command:parameters>
        <command:parameter required="true" variableLength="false" globbing="false" pipelineInput="true (ByValue, ByPropertyName)" position="named">
            <maml:name>Urn</maml:name>
            <maml:description>
                <maml:para>Cadena de caracteres que contiene un nombre de recurso único (URN) de SQL Server. Un URN de SQL Server es una cadena que identifica la ubicación de un objeto en la jerarquía de SQL Server. Los URN tienen la misma información que una ruta de acceso de SQL Server PowerShell pero en un formato diferente. Los Objetos de administración de SQL Server tienen una propiedad Urn.</maml:para>
                                 
            </maml:description>
            <command:parameterValue required="true" variableLength="false">string</command:parameterValue>
            <dev:type>
                <maml:name>string</maml:name>
                <maml:uri/>
            </dev:type>
            <dev:defaultValue></dev:defaultValue>
        </command:parameter>
    </command:parameters>
    <!-- Input - Output section-->
    <command:inputTypes>
        <command:inputType>
            <dev:type>
                <maml:name>String</maml:name>
                <maml:uri/>
                <maml:description />
            </dev:type>
            <maml:description>
                <maml:para>
                    <!-- description -->
                    Cadena de caracteres que contiene un URN de Objetos de administración de SQL Server.
                </maml:para>
            </maml:description>
        </command:inputType>
    </command:inputTypes>
    <command:returnValues>
        <command:returnValue>
            <dev:type>
                <maml:name>String</maml:name>
                <maml:uri />
                <maml:description />
            </dev:type>
            <maml:description>
                <maml:para>
                    <!-- description -->
                    Cadena de caracteres que contiene una ruta de acceso del proveedor de SQL Server PowerShell.
                </maml:para>
            </maml:description>
        </command:returnValue>
    </command:returnValues>
    <!-- Error section-->
    <command:terminatingErrors />
    <command:nonTerminatingErrors />
        <!-- Notes section -->
    <maml:alertSet>
        <maml:title></maml:title>
        <maml:alert>
            <maml:para>
                           
                        </maml:para>
        </maml:alert>
        <maml:alert>
            <maml:para></maml:para>
        </maml:alert>
    </maml:alertSet>
     <!-- Example section -->
    <command:examples>
 
        <command:example>
            <maml:title>
                -------------------------- EXAMPLE 1 --------------------------
            </maml:title>
            <maml:introduction>
                <maml:para>C:\PS&gt;</maml:para>
            </maml:introduction>
              <dev:code>
Set-Location SQLSERVER:\SQL\MyComputer\MyInstance\Databases\AdventureWorks2012
Convert-UrnToPath -Urn (Get-Item .).Urn.ToString()
 
SQLSERVER:\SQL\MyComputer\MyInstance\Databases\AdventureWorks2012 </dev:code>
                   <dev:remarks>
                                <maml:para>Descripción</maml:para>
                                <maml:para>-----------</maml:para>
                      <maml:para>Devuelve una cadena de caracteres que contiene la ruta de acceso actual. En el ejemplo se usa la función ToString() de la propiedad Urn de SMO para devolver el Urn como una cadena de caracteres .</maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
              </dev:remarks>
            <command:commandLines>
                <command:commandLine>
                    <command:commandText></command:commandText>
                </command:commandLine>
            </command:commandLines>
        </command:example>
 
        <command:example>
            <maml:title>
                -------------------------- EXAMPLE 2 --------------------------
            </maml:title>
            <maml:introduction>
                <maml:para>C:\PS&gt;</maml:para>
            </maml:introduction>
              <dev:code>
Set-Location ( Convert-UrnToPath -Urn &quot;Server[@Name='MyComputer']/Database[@Name='AdventureWorks']/Table[@Name='Address' and @Schema = 'Person']&quot; ) </dev:code>
                   <dev:remarks>
                                <maml:para>Descripción</maml:para>
                                <maml:para>-----------</maml:para>
                      <maml:para>Establece la ruta de acceso a la ubicación especificada en un URN de Objetos de administración de SQL Server.</maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
              </dev:remarks>
            <command:commandLines>
                <command:commandLine>
                    <command:commandText></command:commandText>
                </command:commandLine>
            </command:commandLines>
        </command:example>
 
        <command:example>
            <maml:title>
                -------------------------- EXAMPLE 3 --------------------------
            </maml:title>
            <maml:introduction>
                <maml:para>C:\PS&gt;</maml:para>
            </maml:introduction>
              <dev:code>
Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT\Databases
foreach ($Item in Get-ChildItem) { $Item.Urn.ToString() | Convert-UrnToPath}
 
SQLSERVER:\SQL\MyComputer\DEFAULT\Databases\AdventureWorks2012 </dev:code>
                   <dev:remarks>
                                <maml:para>Descripción</maml:para>
                                <maml:para>-----------</maml:para>
                      <maml:para>Devuelve un conjunto de cadenas de caracteres; cada una contiene la ruta de acceso a una base de datos en la instancia predeterminada. Usa una canalización para pasar el URN del nodo actual a Convert-UrnToPath</maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
                            <maml:para></maml:para>
              </dev:remarks>
            <command:commandLines>
                <command:commandLine>
                    <command:commandText></command:commandText>
                </command:commandLine>
            </command:commandLines>
        </command:example>
    </command:examples>
    <!-- Link section -->
    <maml:relatedLinks>
        <maml:navigationLink>
            <maml:linkText>Decode-SqlName</maml:linkText>
            <maml:uri/>
        </maml:navigationLink>
        <maml:navigationLink>
            <maml:linkText>Encode-SqlName</maml:linkText>
            <maml:uri/>
        </maml:navigationLink>
    </maml:relatedLinks>
</command:command>
 
<!-- v 1.3.0.34 -->
<providerHelp>
 
<Name>
    SQLServer
</Name>
 
<Drives>
    <Para>SQLSERVER</Para>
</Drives>
<Synopsis>
    Access SQL Server instances and their databases.
</Synopsis>
 
<DetailedDescription>
    <para>The Microsoft SQL Server PowerShell provider lets you manage the configuration of instances of the SQL Server Database Engine and the objects in those instances. The SQL Server PowerShell provider implements separate path hierarchies for different classes of objects that are supported by the SQL Server management object models.
 
The SQL Server PowerShell provider implements one virtual drive named SQLSERVER:. The SQLSERVER: drive has several folders: \SQL, \SQLPolicy, \SQLRegistration, \Utility, \DAC, \DataCollection, \IntegrationServices, and SQLAS.
 
The SQLServer:\SQL folder lets you navigate to instances of the SQL Server Database Engine and manage the objects in the instances, such as logins, tables, functions, jobs, queues, and mail agents. The SQL folder operates using the objects in these namespaces:
 
  Microsoft.SqlServer.Management.SMO
  Microsoft.SqlServer.Management.SMO.Agent
  Microsoft.SqlServer.Management.SMO.Broker
  Microsoft.SqlServer.Management.SMO.Mail
 
The SQLSERVER:\SQLPolicy folder lets you navigate to instances of the Database Engine that contains a Policy-Based Management policy store and manage objects such as policies and facets. The SQLPolicy folder operates using the objects in the Microsoft.SqlServer.Management.Dmf and Microsoft.SqlServer.Management.Facets namespaces.
 
The SQLSERVER:\SQLRegistration folder lets you navigate to instances of the Database Engine and manage Registered Server objects such as server groups and registered servers. The SQLRegistration folder operates using the objects in the Microsoft.SqlServer.Management.RegisteredServers and Microsoft.SqlServer.Management.RegSvrEnum namespace.
 
The SQLSERVER:\Utility folder lets you navigate to the managed instances and data-tier applications registered in the SQL Server Utility. The Utility folder operates using the objects in the Microsoft.SqlServer.Management.Utility namespace.
 
The SQLServer:\DAC folder lets you navigage through data-tier applications objects such as DAC package files. The DAC folder operates using the objects in the Microsoft.SqlServer.Management.DAC namespace.
 
The SQLServer:\DataCollection folder lets you navigate to instances of the Database Engine and manage Data Collector objects such as collection sets and configuration stores. The DataCollection folder operates using the objects in the Microsoft.SqlServer.Management.Collector namespace.
 
The SQLServer:\IntegrationServices folder lets you manage SQL Server Integration Services objects such as projects, packages, and environments. The IntegrationServices folder operates using the Microsoft.SqlServer.Management.IntegrationServices namespace.
 
The SQLServer:\SQLAS folders lets you manage SQL Server Analysis Services objects such as aggregations, dimensions, and cubes. The SQLAS folder operates using the Microsoft.AnalysisServices namespace.
 
You can navigate the SQLSERVER: paths by using PowerShell path cmdlets such as Get-Location, Set-Location, and Get-ChildItem.
 
The leading part of a SQLSERVER:\SQL path has the form SQLSERVER:\SQL\ComputerName\InstanceName. You must always specify an instance name, even for default instances. Specify DEFAULT for default instance names. The path nodes following the InstanceName alternate between object classes and object names. Schemas are not represented as an object class. When you specify a path node for top level objects in schemas, such as tables or views, the node name must be in the format SchemaName.ObjectName. For example, this is the path to the AddressID column in the Address table of the Person schema:
 
SQLSERVER:\SQL\MyComputer\DEFAULT\Databases\AdventureWorks\Tables\Person.Address\Columns\AddressID
 
To save typing, you can create your own PowerShell drives that map over the first several nodes of an SQL path.
 
The information that is returned by Get-ChildItem depends on which part of the path the cmdlet is executed from:
 
Returns the local computer name and the list of computers to which you have opened Database Engine connections by using WMI:
PS SQLSERVER:\SQL&gt; Get-ChildItem
 
Returns the list of instances on the specified computer:
PS SQLSERVER:\SQL\ComputerName&gt; Get-ChildItem
 
Returns the list of top-level object types from the instance, such as Logins and Databases:
PS SQLSERVER:\SQL\ComputerName\InstanceName&gt; Get-ChildItem.
 
With the SQL Server PowerShell provider, you manage the objects that are exposed in SQL Server paths by using the SQL Server management object model methods and properties for that class of object. For example, you can use the methods of the Microsoft.SQLServer.Management.SMO.Database class to perform actions such as creating, altering, and dropping databases. You can also use the class properties to query the current state of the objects. Use the Get-Member cmdlet to get a list of the methods and properties that are supported for the various objects. For information about the classes, see the namespace reference sections in the SQL Server Books Online.
 
You cannot select, insert, update, or delete data in tables and views by using the SQL Server PowerShell provider. For example, there is no Select() or Insert() method for tables. Use the Invoke-Sqlcmd cmdlet to access and change the data in tables and views.
 
By default, the SQL Server PowerShell provider opens Windows Authentication connections by using the credentials of the Windows account that is running the PowerShell session. See SQL Server Books Online for information about opening a SQL Server Authentication connection using the provider.
 
In complex databases, the lists returned by Get-ChildItem and the PowerShell tab-completion lists can be very large. You can use three system variables created by the SQL Server PowerShell provider to control the size of these lists:
 
$SqlServerMaximumTabCompletion = n
n is an integer that specifies the maximum number of objects in a tab completion list. The default is 0, which means all objects are returned.
 
$SqlServerMaximumChildItems = n
n is an integer that specifies the maximum number of objects returned when you run Get-ChildItem on SQL Server path nodes. The default is 0, which means all objects are returned.
 
$SQLServerIncludeSystemObjects = { $True | $False }
Specifies whether SQL Server system objects are returned by Get-ChildItem or included in tab-completion lists. The default is $True</para>
</DetailedDescription>
 
<Capabilities>
    <para></para>
</Capabilities>
<Filters>
    <para></para>
</Filters>
<Notes>
    SQL Server delimited identifiers are object names that are enclosed in brackets ([Table:Name]) or quotation marks (&quot;View&gt;Name&quot;). Delimited identifiers can contain any Unicode character. The special characters in these names must be either encoded to their hexadecimal representation or escaped for use in PowerShell paths. The hexadecimal encoding for characters uses the format %nn. An example of encoding the colon (:)character in the name &quot;Table:Name&quot; is:
Set-Location &quot;Table%3AName&quot;.
 
The PowerShell escape character is the back tick (`) character that is typically on the key at the top left of the keyboard. An example of escaping an extended character is as follows:
Set-Location &quot;View`&gt;Name&quot;
 
Certain characters, such as the colon character (:), cannot be escaped. They must be encoded. The SQL Server PowerShell provider snapin implements two cmdlets to help encode and decode delimited identifiers: Encode-SqlName and Decode-SqlName.
 
You must supply a registry or directory object for the -Type parameter when using these core cmdlets with a SQLRegistration: drive: Copy-Object, Move-Object, New-Object, Remove-Object, and Rename-Object.
</Notes>
<Tasks>
    <Task>
          <Title>
            Navigating SQLSERVER:\SQL paths
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>This example uses the Set-Location cmdlet to change the path to the SQL folder.</para>
                </Introduction>
                  <Code>
                    Set-Location SQLSERVER:\SQL
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 2 --------------------------
                </Title>
                <Introduction>
                    <para>This example uses Set-Location to change the path to a default instance of the Database Engine</para>
                </Introduction>
                  <Code>
                    Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 3 --------------------------
                </Title>
                <Introduction>
                    <para>This example uses Set-Location to change the path to the AdventureWorks sample database.</para>
                </Introduction>
                  <Code>
                    Set-Location SQLSERVER:\SQL\MyComputer\MyInstance\Databases\AdventureWorks
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
    <Task>
          <Title>
            Build a New PowerShell Drive
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>If you are going to do a lot of work in the AdventureWorks database, create a new AWDB: drive to save typing.</para>
                </Introduction>
                  <Code>
                    New-PSDrive -Name AWDB -Root SQLSERVER:\SQL\MyComputer\DEFAULT\Databases\AdventureWorks -PSProvider SQLServer
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
    <Task>
          <Title>
            Get the Methods and Properties of a SQL Server Object
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>This command sets a variable to the SMO Database class and then gets a list of the methods and properties supported by the class.</para>
                </Introduction>
                  <Code>
                    $MyVar = New-Object Microsoft.SqlServer.Management.SMO.Database
$MyVar | Get-Member -Type Methods
$MyVar | Get-Member -Type Properties
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 2 --------------------------
                </Title>
                <Introduction>
                    <para>This command navigates to the database node in an SQL-based path and get s a list of the properties that are supported for databases.</para>
                </Introduction>
                  <Code>
                    Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT\Databases
Get-Item . | Get-Member -Type Properties
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
    <Task>
          <Title>
            Filter SQL Server Objects by Using SMO Properties
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>This command lists only the tables that are in the AdventureWorks Sales schema.</para>
                </Introduction>
                  <Code>
                    Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT\Databases\AdventureWorks\Tables
Get-ChildItem | WHERE {$_.Schema -eq &quot;Sales&quot;}
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
    <Task>
          <Title>
            Generate Scripts That Create SQL Server Objects
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>This script creates a Views.sql file that contains the CREATE VIEW statements that are required to recreate all of the views that are defined in AdventureWorks.</para>
                </Introduction>
                  <Code>
                    Remove_Item c:\PowerShell\Views.sql
Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT\Databases\AdventureWorks\Views
foreach ($Item in Get-ChildItem) {$Item.Script() | Out-File -Filepath c:\PowerShell\Views.sql -append }
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
    <Task>
          <Title>
            Use SMO to Manage SQL Server Objects
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>This script uses SMO to create a database and then query its state.</para>
                </Introduction>
                  <Code>
                    Set-Location SQLSERVER:\SQL\MyComputer\DEFAULT\Databases
$MyVar = New-Object Microsoft.SqlServer.Management.SMO.Database
$MyVar.Parent = (Get-Item ..)
$MyVar.Name = &quot;NewDB&quot;
$MyVar.Create()
$MyVar.State
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
    <Task>
          <Title>
            Controlling SQL Server Objects in Tab-completion and Get-ChildItem
        </Title>
 
           <Description>
            <para></para>
        </Description>
 
        <Examples>
                        <Example>
                            <Title>
                    -------------------------- EXAMPLE 1 --------------------------
                </Title>
                <Introduction>
                    <para>This script sets the values for the system variables that control the number of SQL Server objects included in tab-completion lists or returned by Get-ChildItem.</para>
                </Introduction>
                  <Code>
                    $SqlServerMaximumTabCompletion = 20
$SqlServerMaximumChildItems = 10
$SqlServerIncludeSystemObjects = $False
dir variable:sqlserver*
                </Code>
                <Remarks>
                    <para></para>
                  </Remarks>
            </Example>
        </Examples>
    </Task>
</Tasks>
<DynamicParameters>
    <DynamicParameter>
        <Name></Name>
 
        <CmdletSupported></CmdletSupported>
 
        <Type>
                    <Name></Name>
              </Type>
 
              <Description></Description>
 
        <PossibleValues>
            <PossibleValue>
                <Value></Value>
 
                <Description>
                    <para></para>
                </Description>
 
            </PossibleValue>
        </PossibleValues>
    </DynamicParameter>
</DynamicParameters>
<RelatedLinks>
    <navigationLink>
        <linkText>about_provider</linkText>
        <uri/>
    </navigationLink>
    <navigationLink>
        <linkText>Encode-SqlName</linkText>
        <uri/>
    </navigationLink>
    <navigationLink>
        <linkText>Decode-SqlName</linkText>
        <uri/>
    </navigationLink>
    <navigationLink>
        <linkText>Invoke-Sqlcmd</linkText>
        <uri/>
    </navigationLink>
    <navigationLink>
        <linkText>New-PSDrive</linkText>
        <uri/>
    </navigationLink>
    <navigationLink>
        <linkText>Get-Member</linkText>
        <uri/>
    </navigationLink>
    <navigationLink>
        <linkText>Invoke-PolicyEvaluation</linkText>
        <uri/>
    </navigationLink>
</RelatedLinks>
 
</providerHelp>
 
 
 
</helpItems>