diff --git a/util/MySqlMigrations/MySqlMigrations.csproj b/util/MySqlMigrations/MySqlMigrations.csproj index 7007f75c2..e0836f738 100644 --- a/util/MySqlMigrations/MySqlMigrations.csproj +++ b/util/MySqlMigrations/MySqlMigrations.csproj @@ -29,5 +29,6 @@ + diff --git a/util/MySqlMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql b/util/MySqlMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql new file mode 100644 index 000000000..d20b5bed7 --- /dev/null +++ b/util/MySqlMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql @@ -0,0 +1,5 @@ +-- Reseller Providers were being created with a NULL value in the `Name` column. +-- This script will populate them with the value from `BusinessName` which was already required. +UPDATE `Provider` +SET `Name` = `BusinessName` +WHERE `Name` IS NULL; diff --git a/util/PostgresMigrations/PostgresMigrations.csproj b/util/PostgresMigrations/PostgresMigrations.csproj index 8d3bed893..febec0cfe 100644 --- a/util/PostgresMigrations/PostgresMigrations.csproj +++ b/util/PostgresMigrations/PostgresMigrations.csproj @@ -24,5 +24,6 @@ + diff --git a/util/PostgresMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql b/util/PostgresMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql new file mode 100644 index 000000000..42c8e7d79 --- /dev/null +++ b/util/PostgresMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql @@ -0,0 +1,5 @@ +-- Reseller Providers were being created with a NULL value in the "Name" column. +-- This script will populate them with the value from "BusinessName" which was already required. +UPDATE "Provider" +SET "Name" = "BusinessName" +WHERE "Name" IS NULL; diff --git a/util/SqliteMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql b/util/SqliteMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql new file mode 100644 index 000000000..42c8e7d79 --- /dev/null +++ b/util/SqliteMigrations/Scripts/2023-08-03_00_PopulateResellerNames.sql @@ -0,0 +1,5 @@ +-- Reseller Providers were being created with a NULL value in the "Name" column. +-- This script will populate them with the value from "BusinessName" which was already required. +UPDATE "Provider" +SET "Name" = "BusinessName" +WHERE "Name" IS NULL; diff --git a/util/SqliteMigrations/SqliteMigrations.csproj b/util/SqliteMigrations/SqliteMigrations.csproj index 54a1dfecf..7ff8f17c3 100644 --- a/util/SqliteMigrations/SqliteMigrations.csproj +++ b/util/SqliteMigrations/SqliteMigrations.csproj @@ -22,4 +22,8 @@ + + + +