Skip to content

A platform for community discussion. Free, open, simple.

DEV: Change uploads.filesize column to bigint (#14334)

Martin Brennan581482003a5f
diff --git a/app/models/upload.rb b/app/models/upload.rb
index 5b4b4be312a..f03883783cb 100644
--- a/app/models/upload.rb
+++ b/app/models/upload.rb
@@ -513,7 +513,7 @@ end
# id :integer not null, primary key
# user_id :integer not null
# original_filename :string not null
-# filesize :integer not null
+# filesize :bigint not null
# width :integer
# height :integer
# url :string not null
diff --git a/db/migrate/20210914011037_change_uploads_filesize_to_bigint.rb b/db/migrate/20210914011037_change_uploads_filesize_to_bigint.rb
new file mode 100644
index 00000000000..5810bd72f9d
--- /dev/null
+++ b/db/migrate/20210914011037_change_uploads_filesize_to_bigint.rb
@@ -0,0 +1,7 @@
+# frozen_string_literal: true
+
+class ChangeUploadsFilesizeToBigint < ActiveRecord::Migration[6.1]
+ def change
+ change_column :uploads, :filesize, :bigint
+ end
+end