From 600b274884a8a85d12ddf284cbfcae5620246fc4 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Wed, 22 Jul 2009 10:17:00 +0200 Subject: [PATCH] =?utf8?q?Neuere=20PostgreSQL-Versionen=20unterst=C3=BCtze?= =?utf8?q?n=20das=20Aliasen=20von=20zu=20aktualisierenden=20Tabellen=20nic?= =?utf8?q?ht.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- sql/Pg-upgrade2/update_date_paid.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sql/Pg-upgrade2/update_date_paid.sql b/sql/Pg-upgrade2/update_date_paid.sql index 30b251f06..9a8b2fd94 100644 --- a/sql/Pg-upgrade2/update_date_paid.sql +++ b/sql/Pg-upgrade2/update_date_paid.sql @@ -1,5 +1,5 @@ -- @tag: update_date_paid -- @description: Aktualisieren des Zahldatums in der Datenbank bei Kreditoren- und Debitorenbuchungen, wo die Funktion "Zahlung buchen" verwendet wurde -- @depends: release_2_6_0 -UPDATE ap a SET datepaid = (SELECT max(ac.transdate) FROM acc_trans ac LEFT JOIN chart c ON (ac.chart_id = c.id) WHERE ac.trans_id=a.id AND c.link LIKE '%paid%') WHERE paid > 0 AND datepaid IS null AND NOT invoice; -UPDATE ar a SET datepaid = (SELECT max(ac.transdate) FROM acc_trans ac LEFT JOIN chart c ON (ac.chart_id = c.id) WHERE ac.trans_id=a.id AND c.link LIKE '%paid%') WHERE paid > 0 AND datepaid IS null AND NOT invoice; +UPDATE ap SET datepaid = (SELECT max(ac.transdate) FROM acc_trans ac LEFT JOIN chart c ON (ac.chart_id = c.id) WHERE ac.trans_id = ap.id AND c.link LIKE '%paid%') WHERE paid > 0 AND datepaid IS null AND NOT invoice; +UPDATE ar SET datepaid = (SELECT max(ac.transdate) FROM acc_trans ac LEFT JOIN chart c ON (ac.chart_id = c.id) WHERE ac.trans_id = ar.id AND c.link LIKE '%paid%') WHERE paid > 0 AND datepaid IS null AND NOT invoice; -- 2.20.1