SELECT T1."Zeile" AS "Zeile",
	T1."Bezeichnung" AS "Bezeichnung",
	T1."Einheiten" AS "Einheiten",
	T1."Erl�se EUR" AS "Erl�se Eur",
	T1."VAK  EUR" AS "Vak Eur",
	T1."DB I  EUR" AS "Db I Eur",
	T1."DB I %" AS "Db I %",
	T1."Rechtseinheit" AS "Rechtseinheit",
	T1."Betrieb" AS "Betrieb",
	T1."Kostenstelle" AS "Kostenstelle",
	T2."Ebene1" AS "Ebene1",
	T2."Ebene2" AS "Ebene2",
	T2."Ebene3" AS "Ebene3",
	T2."Ebene4" AS "Ebene4",
	T2."Ebene5" AS "Ebene5",
	(convert(FLOAT, T1."VAK  EUR")) * - 1 AS "Wert gesamt",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0459)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0537)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0536)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0551)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert1",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0660)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0772)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0771)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0793)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert2",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0979)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0946)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0817)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0857)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert3",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0974)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0981)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0865)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0933)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert4",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0916)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0964)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0855)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0910)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert5",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.1057)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0965)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0909)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0962)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert6",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0900)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0846)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0808)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0837)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert7",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0696)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0847)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0763)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert8",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0656)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0734)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0770)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0776)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert9",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0916)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0928)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0909)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0868)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert10",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0968)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0860)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.1165)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0940)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert11",
	CASE 
		WHEN (T1."Kostenstelle" = '1')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0819)
		WHEN (T1."Kostenstelle" = '2')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0620)
		WHEN (T1."Kostenstelle" = '3')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0832)
		WHEN (T1."Kostenstelle" = '4')
			THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0740)
		ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
		END AS "Wert12",
	(
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0459)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0537)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0536)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0551)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0660)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0772)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0771)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0793)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0979)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0946)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0817)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0857)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0974)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0981)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0865)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0933)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0916)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0964)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0855)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0910)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.1057)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0965)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0909)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0962)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0900)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0846)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0808)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0837)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0696)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0847)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0763)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0656)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0734)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0770)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0776)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0916)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0928)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0909)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0868)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0968)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0860)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.1165)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0940)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) + (
		CASE 
			WHEN (T1."Kostenstelle" = '1')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0819)
			WHEN (T1."Kostenstelle" = '2')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0620)
			WHEN (T1."Kostenstelle" = '3')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0832)
			WHEN (T1."Kostenstelle" = '4')
				THEN (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0740)
			ELSE (((convert(FLOAT, T1."VAK  EUR")) * - 1) * 0.0833)
			END
		) AS "Kontrolle",
	2011 AS "Bookkeep Date",
	T2."Ebene3" AS "Ebene12"
FROM "Planung_gesamt" T1,
	"Struktur_FB" T2
WHERE (T1."Zeile" = (left(T2."Ebene3", 4)))
	AND (T2."Ebene1" = 'Materialaufwand')
