From f85894bd818a0c948a0e3e938f0dd3cdc48f076f Mon Sep 17 00:00:00 2001 From: dingo Date: Wed, 1 Apr 2026 17:01:36 -0400 Subject: [PATCH] Fix hex migration column names to PascalCase (match existing DB convention) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DB columns are PascalCase (e.g. BoardWidth, not board_width). The previous migration used snake_case names — renamed grid_type→GridType and hex_sides→HexSides on pg-forge-01, and updated the migration file to match so future re-runs are correct. Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude Co-Authored-By: Happy --- .../Game/20260401000000_AddHexGridSupport.cs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Server/src/SOR.Database/Migrations/Game/20260401000000_AddHexGridSupport.cs b/Server/src/SOR.Database/Migrations/Game/20260401000000_AddHexGridSupport.cs index 2f61cac..10b58c8 100644 --- a/Server/src/SOR.Database/Migrations/Game/20260401000000_AddHexGridSupport.cs +++ b/Server/src/SOR.Database/Migrations/Game/20260401000000_AddHexGridSupport.cs @@ -11,7 +11,7 @@ namespace SOR.Database.Migrations.Game protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.AddColumn( - name: "grid_type", + name: "GridType", schema: "game", table: "game_rule_sets", type: "text", @@ -19,7 +19,7 @@ namespace SOR.Database.Migrations.Game defaultValue: "Square"); migrationBuilder.AddColumn( - name: "hex_sides", + name: "HexSides", schema: "game", table: "game_rule_sets", type: "integer", @@ -27,7 +27,7 @@ namespace SOR.Database.Migrations.Game defaultValue: 0); migrationBuilder.AddColumn( - name: "grid_type", + name: "GridType", schema: "game", table: "board_templates", type: "text", @@ -35,7 +35,7 @@ namespace SOR.Database.Migrations.Game defaultValue: "Square"); migrationBuilder.AddColumn( - name: "hex_sides", + name: "HexSides", schema: "game", table: "board_templates", type: "integer", @@ -46,10 +46,10 @@ namespace SOR.Database.Migrations.Game /// protected override void Down(MigrationBuilder migrationBuilder) { - migrationBuilder.DropColumn(name: "grid_type", schema: "game", table: "game_rule_sets"); - migrationBuilder.DropColumn(name: "hex_sides", schema: "game", table: "game_rule_sets"); - migrationBuilder.DropColumn(name: "grid_type", schema: "game", table: "board_templates"); - migrationBuilder.DropColumn(name: "hex_sides", schema: "game", table: "board_templates"); + migrationBuilder.DropColumn(name: "GridType", schema: "game", table: "game_rule_sets"); + migrationBuilder.DropColumn(name: "HexSides", schema: "game", table: "game_rule_sets"); + migrationBuilder.DropColumn(name: "GridType", schema: "game", table: "board_templates"); + migrationBuilder.DropColumn(name: "HexSides", schema: "game", table: "board_templates"); } } }