Skip to content

Commit ade185e

Browse files
Merge pull request #671 from erikdarlingdata/fix/release-prep-commits
Release prep: upgrade script + installer success fix
2 parents 827b078 + a3edcfb commit ade185e

4 files changed

Lines changed: 90 additions & 5 deletions

File tree

Installer/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1132,7 +1132,7 @@ Calculate totals and determine success
11321132
*/
11331133
totalSuccessCount = upgradeSuccessCount + installSuccessCount;
11341134
totalFailureCount = upgradeFailureCount + installFailureCount;
1135-
installationSuccessful = (totalFailureCount == 0) || (totalFailureCount == 1 && automatedMode);
1135+
installationSuccessful = totalFailureCount == 0;
11361136

11371137
/*
11381138
Log installation history to database

InstallerGui/Services/InstallationService.cs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -620,10 +620,7 @@ Execute SQL files
620620

621621
result.EndTime = DateTime.Now;
622622

623-
/*Allow query_snapshots to fail - those views get created eventually*/
624-
bool onlyQuerySnapshotsFailed = result.FilesFailed == 1 &&
625-
result.Errors.Any(e => e.FileName.Contains("query_snapshots", StringComparison.OrdinalIgnoreCase));
626-
result.Success = result.FilesFailed == 0 || onlyQuerySnapshotsFailed;
623+
result.Success = result.FilesFailed == 0;
627624

628625
return result;
629626
}
Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
/*
2+
Copyright 2026 Darling Data, LLC
3+
https://www.erikdarling.com/
4+
5+
Upgrade from 2.3.0 to 2.4.0
6+
Re-applies growth/VLF columns for servers that upgraded to 2.3.0 before PR #625 shipped
7+
Adds growth settings and VLF count columns to collect.database_size_stats:
8+
9+
database_size_stats:
10+
- is_percent_growth: new column (bit NULL) — true when auto-growth is percent-based
11+
- growth_pct: new column (integer NULL) — raw growth percent value (set when is_percent_growth = 1)
12+
- vlf_count: new column (integer NULL) — VLF count for log files (NULL for data files)
13+
*/
14+
15+
SET ANSI_NULLS ON;
16+
SET ANSI_PADDING ON;
17+
SET ANSI_WARNINGS ON;
18+
SET ARITHABORT ON;
19+
SET CONCAT_NULL_YIELDS_NULL ON;
20+
SET QUOTED_IDENTIFIER ON;
21+
SET NUMERIC_ROUNDABORT OFF;
22+
SET IMPLICIT_TRANSACTIONS OFF;
23+
SET STATISTICS TIME, IO OFF;
24+
GO
25+
26+
USE PerformanceMonitor;
27+
GO
28+
29+
/*
30+
database_size_stats: add growth settings and VLF count columns
31+
*/
32+
IF OBJECT_ID(N'collect.database_size_stats', N'U') IS NOT NULL
33+
BEGIN
34+
PRINT 'Checking collect.database_size_stats columns...';
35+
36+
IF NOT EXISTS
37+
(
38+
SELECT
39+
1/0
40+
FROM INFORMATION_SCHEMA.COLUMNS
41+
WHERE TABLE_SCHEMA = N'collect'
42+
AND TABLE_NAME = N'database_size_stats'
43+
AND COLUMN_NAME = N'is_percent_growth'
44+
)
45+
BEGIN
46+
ALTER TABLE collect.database_size_stats ADD is_percent_growth bit NULL;
47+
PRINT ' is_percent_growth: added (bit NULL)';
48+
END;
49+
50+
IF NOT EXISTS
51+
(
52+
SELECT
53+
1/0
54+
FROM INFORMATION_SCHEMA.COLUMNS
55+
WHERE TABLE_SCHEMA = N'collect'
56+
AND TABLE_NAME = N'database_size_stats'
57+
AND COLUMN_NAME = N'growth_pct'
58+
)
59+
BEGIN
60+
ALTER TABLE collect.database_size_stats ADD growth_pct integer NULL;
61+
PRINT ' growth_pct: added (integer NULL)';
62+
END;
63+
64+
IF NOT EXISTS
65+
(
66+
SELECT
67+
1/0
68+
FROM INFORMATION_SCHEMA.COLUMNS
69+
WHERE TABLE_SCHEMA = N'collect'
70+
AND TABLE_NAME = N'database_size_stats'
71+
AND COLUMN_NAME = N'vlf_count'
72+
)
73+
BEGIN
74+
ALTER TABLE collect.database_size_stats ADD vlf_count integer NULL;
75+
PRINT ' vlf_count: added (integer NULL)';
76+
END;
77+
78+
PRINT 'database_size_stats complete.';
79+
END;
80+
ELSE
81+
BEGIN
82+
PRINT 'collect.database_size_stats not found — skipping.';
83+
END;
84+
GO
85+
86+
PRINT 'Upgrade 03_add_growth_vlf_columns complete.';
87+
GO
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
01_add_growth_vlf_columns.sql

0 commit comments

Comments
 (0)