diff --git a/src/dbup-sqlserver/AzureSqlConnectionManager.cs b/src/dbup-sqlserver/AzureSqlConnectionManager.cs index 3008b01..a2e16d2 100644 --- a/src/dbup-sqlserver/AzureSqlConnectionManager.cs +++ b/src/dbup-sqlserver/AzureSqlConnectionManager.cs @@ -11,6 +11,13 @@ namespace DbUp.SqlServer; /// Manages an Azure Sql Server database connection. public class AzureSqlConnectionManager : DatabaseConnectionManager { + /// + /// Initializes a new instance of the class using a connection string and an Azure token credential. + /// + /// The SQL connection string. + /// The Azure token credential used for authentication. + /// The resource URI for Azure SQL authentication. + /// Optional tenant ID for multi-tenant authentication scenarios. public AzureSqlConnectionManager( string connectionString, TokenCredential tokenCredential, @@ -34,6 +41,7 @@ public AzureSqlConnectionManager( { } + /// public override IEnumerable SplitScriptIntoCommands(string scriptContents) { var commandSplitter = new SqlCommandSplitter(); diff --git a/src/dbup-sqlserver/Helpers/TemporarySqlDatabase.cs b/src/dbup-sqlserver/Helpers/TemporarySqlDatabase.cs index 8a84c2c..f7a0933 100644 --- a/src/dbup-sqlserver/Helpers/TemporarySqlDatabase.cs +++ b/src/dbup-sqlserver/Helpers/TemporarySqlDatabase.cs @@ -26,6 +26,7 @@ public TemporarySqlDatabase(string name) : this(name, localSqlInstance) { } /// Initializes a new instance of the class. /// /// The name. + /// The name of the instance. public TemporarySqlDatabase(string name, string instanceName) : this(new SqlConnectionStringBuilder($"Server={instanceName};Database={name};Trusted_connection=true;Pooling=false")) { diff --git a/src/dbup-sqlserver/SqlConnectionManager.cs b/src/dbup-sqlserver/SqlConnectionManager.cs index d2dc6cf..0f48f4a 100644 --- a/src/dbup-sqlserver/SqlConnectionManager.cs +++ b/src/dbup-sqlserver/SqlConnectionManager.cs @@ -26,6 +26,7 @@ public SqlConnectionManager(string connectionString) })) { } + /// public override IEnumerable SplitScriptIntoCommands(string scriptContents) { var commandSplitter = new SqlCommandSplitter(); diff --git a/src/dbup-sqlserver/SqlScriptExecutor.cs b/src/dbup-sqlserver/SqlScriptExecutor.cs index 2e5a45c..1ceec7c 100644 --- a/src/dbup-sqlserver/SqlScriptExecutor.cs +++ b/src/dbup-sqlserver/SqlScriptExecutor.cs @@ -28,11 +28,13 @@ public SqlScriptExecutor(Func connectionManagerFactory, Func { } + /// protected override string GetVerifySchemaSql(string schema) { return string.Format(@"IF NOT EXISTS (SELECT * FROM sys.schemas WHERE name = N'{0}') Exec('CREATE SCHEMA [{0}]')", Schema); } + /// protected override void ExecuteCommandsWithinExceptionHandler(int index, SqlScript script, Action executeCommand) { try diff --git a/src/dbup-sqlserver/SqlServerObjectParser.cs b/src/dbup-sqlserver/SqlServerObjectParser.cs index 6080d4b..3eaae45 100644 --- a/src/dbup-sqlserver/SqlServerObjectParser.cs +++ b/src/dbup-sqlserver/SqlServerObjectParser.cs @@ -9,6 +9,9 @@ namespace DbUp.SqlServer /// public class SqlServerObjectParser : SqlObjectParser { + /// + /// Initializes a new instance of the class. + /// public SqlServerObjectParser() : base("[", "]") { diff --git a/src/dbup-sqlserver/SqlTableJournal.cs b/src/dbup-sqlserver/SqlTableJournal.cs index 79e0a33..9a1d0c0 100644 --- a/src/dbup-sqlserver/SqlTableJournal.cs +++ b/src/dbup-sqlserver/SqlTableJournal.cs @@ -26,16 +26,19 @@ public SqlTableJournal(Func connectionManager, Func protected override string GetInsertJournalEntrySql(string @scriptName, string @applied) { return $"insert into {FqSchemaTableName} (ScriptName, Applied) values ({@scriptName}, {@applied})"; } + /// protected override string GetJournalEntriesSql() { return $"select [ScriptName] from {FqSchemaTableName} order by [ScriptName]"; } + /// protected override string CreateSchemaTableSql(string quotedPrimaryKeyName) { return diff --git a/src/dbup-sqlserver/dbup-sqlserver.csproj b/src/dbup-sqlserver/dbup-sqlserver.csproj index 8340f0e..6861170 100644 --- a/src/dbup-sqlserver/dbup-sqlserver.csproj +++ b/src/dbup-sqlserver/dbup-sqlserver.csproj @@ -14,6 +14,7 @@ true https://github.com/DbUp/dbup-sqlserver.git dbup-icon.png + true