Get-VESQLPublishedDatabase
Short Description
Returns published Microsoft SQL Server databases.
Product: Veeam Backup & Replication
Product Edition: Community, Standard, Enterprise, Enterprise Plus, Veeam Universal License
Syntax
|
Get-VESQLPublishedDatabase [-Session] <IVESQLRestoreSession> [[-Name] <String[]>] [-ServerName <String[]>] [-InstanceName <String[]>] [<CommonParameters>] |
Detailed Description
This cmdlet returns an array of published Microsoft SQL Server databases.
Note |
|
The cmdlet returns Microsoft SQL Server databases published in the PowerShell console only. The cmdlet does not return Microsoft SQL Server databases published in the Veeam Backup & Replication console. |
Parameters
|
Parameter |
Description |
Type |
Required |
Position |
Accept Pipeline Input |
|---|---|---|---|---|---|
|
InstanceName |
Specifies an array of target instance names. The cmdlet will get Microsoft SQL Server databases that are published to these instances. |
|
False |
Named |
False |
|
Name |
Specifies an array of names for Microsoft SQL Server databases. The cmdlet will return information about databases with the specified names. |
|
False |
1 |
False |
|
ServerName |
Specifies an array of target server names (as DNS names or IP addresses). The cmdlet will get Microsoft SQL Server databases that are published to these servers. |
|
False |
Named |
False |
|
Session |
Specifies a restore session. The cmdlet will return information about Microsoft SQL Server databases added to the specified restore session.
Accepts the |
|
True |
0 |
True (ByValue) |
<CommonParameters>
This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About Common Parameters section of Microsoft Learn.
Output Object
The cmdlet returns the VESQLPublishedDatabase[] array that contains published Microsoft SQL Server databases.
Examples
Example 1. Getting all Published Microsoft SQL Server Databases
|
This example shows how to get an array of all published Microsoft SQL Server databases within a restore session.
Perform the following steps:
|
Example 2. Getting All Published Microsoft SQL Server Databases with Specific Names Belonging to Specific Instances
|
This example shows how to get an array of published Microsoft SQL Server databases with specific names belonging to specific instances on the backup file.
Perform the following steps:
|
Example 3. Getting All Microsoft SQL Server Databases Published on Specific Servers
|
This example shows how to get an array of all Microsoft SQL Server databases published on the specified servers.
Perform the following steps:
|
Related Commands
Get-VESQLRestoreSessionReturns active restore sessions started to perform operations with backed-up Microsoft SQL Server databases.