Použijte rozšířený editor POWER QUERY a vložte do něj kód.
Pak dejte uložit a načíst.
Dostanete tabulku s jednotlivými dny. Místo vzorců bych pak použil kontingenční tabulku se stránkovým filtrem Rok, Týden
V řádku Source si změňte cestu ke svému souboru.
Pokud navíc nastavíte Aktualizovat při otevření (u dat i u KT), máte prakticky hotovo
let
Source = Excel.Workbook(File.Contents("X:\38148_odpady-2017.xlsx"), null, true),
#"DENNÍ 2017_Sheet" = Source{[Item="DENNÍ 2017",Kind="Sheet"]}[Data],
#"Removed Columns" = Table.RemoveColumns(#"DENNÍ 2017_Sheet",{"Column12", "Column13", "Column14", "Column15", "Column16", "Column17", "Column18", "Column19", "Column20", "Column21", "Column22", "Column23", "Column24", "Column25", "Column26", "Column27", "Column28", "Column29", "Column30", "Column31", "Column32", "Column33", "Column34", "Column35", "Column36", "Column37", "Column38", "Column39", "Column40", "Column41", "Column42", "Column43", "Column44", "Column45", "Column46", "Column47", "Column48", "Column49", "Column50", "Column51", "Column52", "Column53", "Column54", "Column55", "Column56", "Column57", "Column58", "Column59", "Column60", "Column61", "Column62", "Column63", "Column64", "Column65", "Column66", "Column67", "Column68", "Column69", "Column70", "Column71", "Column72", "Column73", "Column74", "Column75", "Column76", "Column77", "Column78", "Column79", "Column80", "Column81", "Column82", "Column83", "Column84", "Column85", "Column86", "Column87", "Column88", "Column89", "Column90", "Column91", "Column92", "Column93", "Column94", "Column95", "Column96", "Column97", "Column98", "Column99", "Column100", "Column101", "Column102", "Column103", "Column104", "Column105", "Column106", "Column107", "Column108", "Column109", "Column110", "Column111", "Column112", "Column113", "Column114", "Column115", "Column116", "Column117", "Column118"}),
#"Filtered Rows" = Table.SelectRows(#"Removed Columns", each ([Column1] <> null)),
#"Promoted Headers" = Table.PromoteHeaders(#"Filtered Rows", [PromoteAllScalars=true]),
#"Added Custom" = Table.AddColumn(#"Promoted Headers", "Týden", each Date.WeekOfYear([Datum])),
#"Added Custom1" = Table.AddColumn(#"Added Custom", "Rok", each Date.Year([Datum])),
#"Removed Errors" = Table.RemoveRowsWithErrors(#"Added Custom1", {"Týden"}),
#"Removed Errors1" = Table.RemoveRowsWithErrors(#"Removed Errors", {"Rok"}),
#"Changed Type" = Table.TransformColumnTypes(#"Removed Errors1",{{"Datum", type date}})
in
#"Changed Type"citovat