Skip to content

Commit

Permalink
Merge branch 'main' into save-as-excel
Browse files Browse the repository at this point in the history
  • Loading branch information
ckaczor committed Oct 10, 2023
2 parents 7ddbff4 + f0d3a0d commit eefa83f
Show file tree
Hide file tree
Showing 31 changed files with 1,645 additions and 1,483 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -925,6 +925,7 @@ public bool ReplaceUri(string originalOwnerUri, string newOwnerUri)
{
return false;
}
info.OwnerUri = newOwnerUri;
OwnerToConnectionMap.Remove(originalOwnerUri);
OwnerToConnectionMap.Add(newOwnerUri, info);
return true;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
using Microsoft.SqlServer.Management.Smo;
using SMO = Microsoft.SqlServer.Management.Smo;
using Microsoft.SqlTools.ServiceLayer.Management;
using System.IO;

namespace Microsoft.SqlTools.ServiceLayer.DisasterRecovery
{
Expand Down Expand Up @@ -376,12 +375,9 @@ public static string[] GetAssociatedFilePaths(ServerConnection connection, strin

foreach (DataRow currentRow in dataTable.Rows)
{
var primaryFolder = Path.GetDirectoryName(primaryFilePath);
var originalPath = (string)currentRow["FileName"];
var originalFileName = Path.GetFileName(originalPath);
var filePath = Path.Join(primaryFolder, originalFileName);
var filePath = (string)currentRow["FileName"];

// Check if file exists with the constructed path.
// Check if file exists with the provided path.
// If it's an XI (XStore Integration) path, then assume it exists, otherwise retrieve info for the file to check if it exists.
var exists = true;
var isXIPath = PathWrapper.IsXIPath(primaryFilePath);
Expand Down
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.de.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@ Der Abfrageprozessor schätzt, dass durch das Implementieren des folgenden Index
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 Tage</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>Ungültiger Wert für Datenbankschemaanbieter: "{0}"; Erwartet wurde das Format "Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider".</value>
</data>
</root>
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.es.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@ El procesador de consultas estima que la implementación del siguiente índice p
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 días</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>Valor no válido para el proveedor de esquema de base de datos: ''{0}''; se esperaba tener el formato ''Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider''.</value>
</data>
</root>
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.fr.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@ Le processeur de requêtes estime que l'implémentation de l'index suivant peut
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 jours</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>Valeur non valide pour le fournisseur de schéma de base de données : « {0} » ; devrait être sous la forme « Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider ».</value>
</data>
</root>
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.it.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@ Query Processor stima che l'implementazione del seguente indice potrebbe miglior
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 giorni</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>Valore non valido per il provider dello schema del database: '{0}'; il formato previsto è 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</value>
</data>
</root>
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.ja.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 日</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>データベース スキーマ プロバイダー '{0}' の値が無効です。'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider' の形式である必要があります。</value>
</data>
</root>
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.ko.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7일</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>데이터베이스 스키마 공급자의 값 '{0}'이(가) 잘못되었습니다. 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider' 형식이어야 합니다.</value>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@ O Processador de Consultas estima que a implementação do índice a seguir pode
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 dias</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>Valor inválido para o Provedor de Esquema de Banco de Dados: espera-se que '{0}'; que esteja no formato 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</value>
</data>
</root>
3 changes: 3 additions & 0 deletions src/Microsoft.SqlTools.ServiceLayer/Localization/sr.ru.resx
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 дней</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>Недопустимое значение поставщика схемы базы данных: '{0}'; должно быть 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</value>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 天</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>数据库架构提供程序“{0}”的值无效; 应采用“Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider”格式。</value>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -4483,4 +4483,7 @@
<data name="queryStore_stale_threshold_SevenDays" xml:space="preserve">
<value>7 天</value>
</data>
<data name="InvalidDspFormatError" xml:space="preserve">
<value>資料庫架構提供者的值無效: '{0}';格式必須是 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'。</value>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ Der Abfrageprozessor schätzt, dass durch das Implementieren des folgenden Index
<target state="translated">7 Tage</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">Ungültiger Wert für Datenbankschemaanbieter: "{0}"; Erwartet wurde das Format "Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider".</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ El procesador de consultas estima que la implementación del siguiente índice p
<target state="translated">7 días</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">Valor no válido para el proveedor de esquema de base de datos: ''{0}''; se esperaba tener el formato ''Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider''.</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ Le processeur de requêtes estime que l'implémentation de l'index suivant peut
<target state="translated">7 jours</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">Valeur non valide pour le fournisseur de schéma de base de données : « {0} » ; devrait être sous la forme « Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider ».</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ Query Processor stima che l'implementazione del seguente indice potrebbe miglior
<target state="translated">7 giorni</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">Valore non valido per il provider dello schema del database: '{0}'; il formato previsto è 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ The Query Processor estimates that implementing the following index could improv
<target state="translated">7 日</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">データベース スキーマ プロバイダー '{0}' の値が無効です。'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider' の形式である必要があります。</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ The Query Processor estimates that implementing the following index could improv
<target state="translated">7일</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">데이터베이스 스키마 공급자의 값 '{0}'이(가) 잘못되었습니다. 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider' 형식이어야 합니다.</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ O Processador de Consultas estima que a implementação do índice a seguir pode
<target state="translated">7 dias</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">Valor inválido para o Provedor de Esquema de Banco de Dados: espera-se que '{0}'; que esteja no formato 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ The Query Processor estimates that implementing the following index could improv
<target state="translated">7 дней</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">Недопустимое значение поставщика схемы базы данных: '{0}'; должно быть 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ The Query Processor estimates that implementing the following index could improv
<target state="translated">7 天</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">数据库架构提供程序“{0}”的值无效; 应采用“Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider”格式。</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -7364,6 +7364,12 @@ The Query Processor estimates that implementing the following index could improv
<target state="translated">7 天</target>
<note></note>
</trans-unit>
<trans-unit id="InvalidDspFormatError">
<source>Invalid value for Database Schema Provider: '{0}'; expected to be in the form 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'.</source>
<target state="translated">資料庫架構提供者的值無效: '{0}';格式必須是 'Microsoft.Data.Tools.Schema.Sql.SqlAzureV12DatabaseSchemaProvider'。</target>
<note>.
Parameters: 0 - dsp (string) </note>
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -111,18 +111,11 @@ public static bool IsSql13SP1OrLater(Version version)

public static bool IsXTPSupportedOnServer(SMO.Server server)
{
if(server.DatabaseEngineEdition == DatabaseEngineEdition.SqlOnDemand)
if (server.DatabaseEngineEdition == DatabaseEngineEdition.SqlOnDemand)
{
return false;
}
bool isXTPSupported = false;

if (server.ConnectionContext.ExecuteScalar("SELECT SERVERPROPERTY('IsXTPSupported')") != DBNull.Value)
{
isXTPSupported = server.IsXTPSupported;
}

return isXTPSupported;
return server.IsSupportedProperty(nameof(server.IsXTPSupported)) && server.IsXTPSupported;
}

public static bool IsPolybasedInstalledOnServer(SMO.Server server)
Expand Down
Loading

0 comments on commit eefa83f

Please sign in to comment.