From 8dd76e6e2f7640e4d51913b039975c4ebd6ae87e Mon Sep 17 00:00:00 2001 From: mrgoldy Date: Thu, 12 Mar 2020 22:13:14 +0100 Subject: [PATCH] [ticket/16245] Cast attachment filesize to bigint PHPBB3-16245 --- phpBB/includes/acp/acp_attachments.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpBB/includes/acp/acp_attachments.php b/phpBB/includes/acp/acp_attachments.php index f5692c521c..0961223002 100644 --- a/phpBB/includes/acp/acp_attachments.php +++ b/phpBB/includes/acp/acp_attachments.php @@ -1309,7 +1309,7 @@ class acp_attachments */ public function get_attachment_stats($limit = '') { - $sql = 'SELECT COUNT(a.attach_id) AS num_files, SUM(a.filesize) AS upload_dir_size + $sql = 'SELECT COUNT(a.attach_id) AS num_files, SUM(' . $this->db->cast_expr_to_bigint('a.filesize') . ') AS upload_dir_size FROM ' . ATTACHMENTS_TABLE . " a WHERE a.is_orphan = 0 $limit";