From: Moritz Bunkus Date: Tue, 12 Dec 2006 14:49:04 +0000 (+0000) Subject: Datenbankupgrade Buchungsgruppen: Wenn EUR gesetzt ist, dann erwartet das Query einen... X-Git-Tag: release-2.4.0^2~66 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=584599b21272c3422b729fe4368d31409c7195b5;p=kivitendo-erp.git Datenbankupgrade Buchungsgruppen: Wenn EUR gesetzt ist, dann erwartet das Query einen Parameter mehr. --- diff --git a/sql/Pg-upgrade/Pg-upgrade-2.2.0.33-2.2.0.34.pl b/sql/Pg-upgrade/Pg-upgrade-2.2.0.33-2.2.0.34.pl index 89f42cf7c..2b0765f9c 100644 --- a/sql/Pg-upgrade/Pg-upgrade-2.2.0.33-2.2.0.34.pl +++ b/sql/Pg-upgrade/Pg-upgrade-2.2.0.33-2.2.0.34.pl @@ -186,8 +186,10 @@ sub update_known_buchungsgruppen { foreach my $bg (@{$buchungsgruppen}) { if (($ref->{"income_accno_id"} == $bg->{"income_accno_id_0"}) && ($ref->{"expense_accno_id"} == $bg->{"expense_accno_id_0"})) { - $sth_update->execute($bg->{"id"}, $ref->{"id"}) || - mydberror($query_update . " ($bg->{id}, $ref->{id})"); + my @values = ($bg->{"id"}, $ref->{"id"}); + splice(@values, 1, 0, undef) if ($main::eur); + $sth_update->execute(@values) || + mydberror($query_update . " (" . join(", ", @values) . ")"); last; } }