From: Moritz Bunkus Date: Wed, 28 Feb 2007 13:55:01 +0000 (+0000) Subject: Ungültige und fehlende Einträge Einträge in der Spalte "taxkey_id" in der Kontenrahme... X-Git-Tag: release-2.4.3^2~647 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=28ae03226a30c6f647aa8532809f8e80abaae20b;p=kivitendo-erp.git Ungültige und fehlende Einträge Einträge in der Spalte "taxkey_id" in der Kontenrahmendefinition vom SKR03. --- diff --git a/sql/Germany-DATEV-SKR03EU-chart.sql b/sql/Germany-DATEV-SKR03EU-chart.sql index ac30924df..47bbbd656 100644 --- a/sql/Germany-DATEV-SKR03EU-chart.sql +++ b/sql/Germany-DATEV-SKR03EU-chart.sql @@ -271,8 +271,8 @@ INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, ta INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4635', 'Geschenke über 35EUR nicht abzugsf.', 'A', 'E', 'AP_amount', '4635', 0, NULL, 15, NULL, 18, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4655', 'Nicht abzugsf.Betriebsausg.a.Werbe-Repräsentatisonk.etc.', 'A', 'E', 'AP_amount', '4655', 9, NULL, 15, NULL, 24, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4805', 'Rep.u.Instandhalt.v.and.Anlagen u.Betriebs-u.Geschäftsausst.', 'A', 'E', 'AP_amount', '4805', 9, NULL, 18, NULL, 19, FALSE); -INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8190', 'Erlöse,die mit den Durchschnittssätzen d.§24UStG vers.werd.', 'A', 'I', 'AR_amount', '8190', NULL, NULL, NULL, NULL, 1, FALSE); -INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8195', 'Erlöse als Kleinunternehmer i.S.d.§19(1)UStG', 'A', 'I', 'AR_amount', '8195', NULL, NULL, 1, NULL, 1, FALSE); +INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8190', 'Erlöse,die mit den Durchschnittssätzen d.§24UStG vers.werd.', 'A', 'I', 'AR_amount', '8190', 0, NULL, NULL, NULL, 1, FALSE); +INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8195', 'Erlöse als Kleinunternehmer i.S.d.§19(1)UStG', 'A', 'I', 'AR_amount', '8195', 0, NULL, 1, NULL, 1, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8807', 'Erlöse a.Verk.Sachanlagen steuerfrei§4Nr.1aUStG(b.Buchverlust)', 'A', 'E', '', '8807', 0, NULL, NULL, NULL, 1, TRUE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8808', 'Erlöse a.Verk.Sachanlagen steuerfrei§4Nr.1bUStG(b.Buchverlust)', 'A', 'E', '', '8808', 0, NULL, NULL, NULL, 1, TRUE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('8809', 'Erlöse aus Verk.Sachanlagevermögen16% USt (bei Buchverlust)', 'A', 'E', '', '8809', 0, NULL, NULL, NULL, 2, TRUE); @@ -312,7 +312,7 @@ INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, ta INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4180', 'Bedienungsgelder', 'A', 'E', '', '4180', 0, NULL, 10, NULL, 9, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4826', 'Außerplan.AfA a.immat.Vermögensgeg.', 'A', 'E', '', '4826', 0, NULL, 17, NULL, 25, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4850', 'Abschr.a.Sachanl.aufgr.steuerl.Sondervorschriften', 'A', 'E', '', '4850', 0, NULL, 17, NULL, 25, FALSE); -INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4870', 'Abschreibungen auf Finanzanlagen', 'A', 'E', '', '4870', NULL, NULL, NULL, NULL, NULL, FALSE); +INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4870', 'Abschreibungen auf Finanzanlagen', 'A', 'E', '', '4870', 0, NULL, NULL, NULL, NULL, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4875', 'Abschr.a.Wertp.d.Umlaufvermögens', 'A', 'E', '', '4875', 0, NULL, 17, NULL, NULL, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('4880', 'Abschreibungen auf Umlaufverm. o.Wertpapiere (soweit unübl.Höhe', 'A', 'E', '', '4880', 0, NULL, 17, NULL, NULL, FALSE); INSERT INTO chart (accno, description, charttype, category, link, gifi_accno, taxkey_id, pos_ustva, pos_bwa, pos_bilanz, pos_eur, datevautomatik) VALUES ('2208', 'Solidaritätszuschlag', 'A', 'E', '', '2208', 0, NULL, 35, NULL, NULL, FALSE); diff --git a/sql/Pg-upgrade2/invalid_taxkeys_2.sql b/sql/Pg-upgrade2/invalid_taxkeys_2.sql new file mode 100644 index 000000000..f5f72c79e --- /dev/null +++ b/sql/Pg-upgrade2/invalid_taxkeys_2.sql @@ -0,0 +1,4 @@ +-- @tag: invalid_taxkeys_2 +-- @description: Ungültige Steuerschlüssel in den Kontenrahmendefinitionen und daraus resultierende falsche Einträge in anderen Tabellen werden korrigiert. +-- @depends: release_2_4_2 +UPDATE chart SET taxkey_id = 0 WHERE taxkey_id ISNULL; diff --git a/sql/Pg-upgrade2/ustva_setup_2007_update_chart_taxkeys_tax.sql b/sql/Pg-upgrade2/ustva_setup_2007_update_chart_taxkeys_tax.sql index b2d11b5d6..56737e80e 100644 --- a/sql/Pg-upgrade2/ustva_setup_2007_update_chart_taxkeys_tax.sql +++ b/sql/Pg-upgrade2/ustva_setup_2007_update_chart_taxkeys_tax.sql @@ -13,11 +13,13 @@ INSERT INTO chart ( accno, description, - charttype, category, link + charttype, category, link, + taxkey_id ) SELECT '1570','Anrechenbare Vorsteuer', - 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax' + 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', + 0 WHERE EXISTS ( -- update only for SKR03 SELECT coa FROM defaults WHERE defaults.coa='Germany-DATEV-SKR03EU' @@ -26,11 +28,13 @@ WHERE EXISTS ( -- update only for SKR03 INSERT INTO chart ( accno, description, - charttype, category, link + charttype, category, link, + taxkey_id ) SELECT '1574','Abziehbare Vorsteuer aus innergem. Erwerb 19 %', - 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax' + 'A', 'E', 'AP_tax:IC_taxpart:IC_taxservice:CT_tax', + 0 WHERE EXISTS ( -- update only for SKR03 SELECT coa FROM defaults WHERE defaults.coa='Germany-DATEV-SKR03EU' @@ -39,11 +43,13 @@ WHERE EXISTS ( -- update only for SKR03 INSERT INTO chart ( accno, description, - charttype, category, link + charttype, category, link, + taxkey_id ) SELECT '1774','Umsatzsteuer aus innergem. Erwerb 19 %', - 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax' + 'A', 'I', 'AR_tax:IC_taxpart:IC_taxservice:CT_tax', + 0 WHERE EXISTS ( -- update only for SKR03 SELECT coa FROM defaults WHERE defaults.coa='Germany-DATEV-SKR03EU'