From 4db45674d38f3ef54879848b3b78a2f6b6ef98de Mon Sep 17 00:00:00 2001 From: Janos SUTO Date: Thu, 14 Oct 2021 11:01:58 +0200 Subject: [PATCH] Added attachments column to v_messages view Signed-off-by: Janos SUTO --- util/db-mysql.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/db-mysql.sql b/util/db-mysql.sql index ffc93e1f..f90bc19e 100644 --- a/util/db-mysql.sql +++ b/util/db-mysql.sql @@ -73,7 +73,7 @@ create index `rcpt_idx3` on `rcpt`(`todomain`); drop view if exists `v_messages`; -create view `v_messages` AS select `metadata`.`id` AS `id`,`metadata`.`piler_id` AS `piler_id`,`metadata`.`from` AS `from`,`metadata`.`fromdomain` AS `fromdomain`,`rcpt`.`to` AS `to`,`rcpt`.`todomain` AS `todomain`,`metadata`.`subject` AS `subject`, `metadata`.`size` AS `size`, `metadata`.`direction` AS `direction`, `metadata`.`sent` AS `sent`, `metadata`.`retained` AS `retained`, `metadata`.`arrived` AS `arrived`, `metadata`.`digest` AS `digest`, `metadata`.`bodydigest` AS `bodydigest`, `metadata`.`deleted` AS `deleted` from (`metadata` join `rcpt`) where (`metadata`.`id` = `rcpt`.`id`); +create view `v_messages` AS select `metadata`.`id` AS `id`,`metadata`.`piler_id` AS `piler_id`,`metadata`.`from` AS `from`,`metadata`.`fromdomain` AS `fromdomain`,`rcpt`.`to` AS `to`,`rcpt`.`todomain` AS `todomain`,`metadata`.`subject` AS `subject`, `metadata`.`size` AS `size`, `metadata`.`direction` AS `direction`, `metadata`.`sent` AS `sent`, `metadata`.`retained` AS `retained`, `metadata`.`arrived` AS `arrived`, `metadata`.`digest` AS `digest`, `metadata`.`bodydigest` AS `bodydigest`, `metadata`.`deleted` AS `deleted`, `metadata`.`attachments` AS `attachments` from (`metadata` join `rcpt`) where (`metadata`.`id` = `rcpt`.`id`); create table if not exists `attachment` (