Bugzilla – Attachment 187918 Details for
Bug 38489
EDI should be updated to use the new FTP/SFTP Servers management page
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38489: (follow-up) Make old db_rev more idempotent 2
Bug-38489-follow-up-Make-old-dbrev-more-idempotent.patch (text/plain), 2.41 KB, created by
Martin Renvoize (ashimema)
on 2025-10-15 15:47:22 UTC
(
hide
)
Description:
Bug 38489: (follow-up) Make old db_rev more idempotent 2
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2025-10-15 15:47:22 UTC
Size:
2.41 KB
patch
obsolete
>From 03b1c81f4565c6ecc43a49a7d2fe1e8c6572003f Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@openfifth.co.uk> >Date: Wed, 15 Oct 2025 16:41:38 +0100 >Subject: [PATCH] Bug 38489: (follow-up) Make old db_rev more idempotent 2 > >In the unit test system we reset the database version to 21.11 after >having upgraded a long way past that. The 231200022 update appears not >to be fully idempotent, so we fail running through the upgrade. >--- > installer/data/mysql/db_revs/231200022.pl | 32 ++++++++++++----------- > 1 file changed, 17 insertions(+), 15 deletions(-) > >diff --git a/installer/data/mysql/db_revs/231200022.pl b/installer/data/mysql/db_revs/231200022.pl >index c823a103f51..7b36eec4a15 100755 >--- a/installer/data/mysql/db_revs/231200022.pl >+++ b/installer/data/mysql/db_revs/231200022.pl >@@ -7,24 +7,26 @@ return { > my ($args) = @_; > my ( $dbh, $out ) = @$args{qw(dbh out)}; > >- if ( !column_exists( 'vendor_edi_accounts', 'download_port' ) ) { >- $dbh->do( >- q{ >- ALTER TABLE vendor_edi_accounts ADD COLUMN `download_port` int(11) DEFAULT NULL AFTER `password` >- } >- ); >+ if ( column_exists( 'vendor_edi_accounts', 'password' ) ) { >+ if ( !column_exists( 'vendor_edi_accounts', 'download_port' ) ) { >+ $dbh->do( >+ q{ >+ ALTER TABLE vendor_edi_accounts ADD COLUMN `download_port` int(11) DEFAULT NULL AFTER `password` >+ } >+ ); > >- say $out "Added column 'vendor_edi_accounts.download_port'"; >- } >+ say $out "Added column 'vendor_edi_accounts.download_port'"; >+ } > >- if ( !column_exists( 'vendor_edi_accounts', 'upload_port' ) ) { >- $dbh->do( >- q{ >- ALTER TABLE vendor_edi_accounts ADD COLUMN `upload_port` int(11) DEFAULT NULL AFTER `download_port` >- } >- ); >+ if ( !column_exists( 'vendor_edi_accounts', 'upload_port' ) ) { >+ $dbh->do( >+ q{ >+ ALTER TABLE vendor_edi_accounts ADD COLUMN `upload_port` int(11) DEFAULT NULL AFTER `download_port` >+ } >+ ); > >- say $out "Added column 'vendor_edi_accounts.upload_port'"; >+ say $out "Added column 'vendor_edi_accounts.upload_port'"; >+ } > } > }, > }; >-- >2.51.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 38489
:
175204
|
175205
|
175206
|
175207
|
176118
|
176119
|
176161
|
185324
|
186819
|
186820
|
186845
|
186846
|
186847
|
186848
|
186849
|
186850
|
186851
|
186852
|
186854
|
187080
|
187081
|
187082
|
187083
|
187084
|
187085
|
187086
|
187087
|
187088
|
187089
|
187108
|
187147
|
187148
|
187149
|
187150
|
187151
|
187152
|
187153
|
187154
|
187155
|
187156
|
187157
|
187158
|
187159
|
187270
|
187271
|
187272
|
187273
|
187274
|
187275
|
187276
|
187277
|
187278
|
187279
|
187280
|
187281
|
187283
|
187284
|
187285
|
187286
|
187287
|
187288
|
187289
|
187290
|
187291
|
187292
|
187293
|
187294
|
187861
|
187862
|
187863
|
187864
|
187865
|
187866
|
187867
|
187868
|
187869
|
187870
|
187871
|
187872
|
187873
|
187897
|
187916
|
187918
|
187923
|
187924
|
187925
|
187926