Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Prezada comunidade, eu importei meus dados a partir de uma tabela .xlsx e preciso criar uma nova tabela a partir do somatório de valores conteúdos em outros colunas da minha tabela importada. Na tabela importada, essas almofadas são inspiradas com o 'header' em dados, por exemplo, "01/01/2022" "01/02/2022", assim sucessivamente. Na minha nova tabela preciso criar 3 novas sonoras, uma para dados, como tudo é relacionado a "2022" pode ser apenas os meses apresentados "janeiro", "fevereiro"..... No PowerQuery adicionoui uma nova tabela e a primeira coluna implementei manualmente os meses, e fui em "adicionar nova coluna", e a seguinte fórmula foi executada:
= Table.AddColumn(#"Tipo Alterado1", "Orçado", each {List.Sum(Table.Column(#"Dados (2)", "1/1/2022")), List.Sum(Table.Column (#"Dados (2)", "2/1/2022")), List.Sum(Table.Column(#"Dados (2)", "3/1/2022")), List.Sum(Table .Column(#"Dados (2)", "4/1/2022")), List.Sum(Table.Column(#"Dados (2)", "5/1/2022")), List.Sum (Table.Column(#"Dados (2)", "6/1/2022")), List.Sum(Table.Column(#"Dados (2)", "7/1/2022")), List .Sum(Table.Column(#"Dados (2)", "8/1/2022")), List.Sum(Table.Column(#"Dados (2)", "9/1/2022")) , List.Sum(Table.Column(#"Dados (2)", "10/1/2022")), List.Sum(Table.Column(#"Dados (2)", "11/1/2022" )), Lista.Soma(Tabela.Column(#"Dados (2)", "12/1/2022"))})
Nenhuma coluna sendo "Orçada" a partir de uma lista, criada de acordo com a somatória de valores de cada coluna dos meus dados importados. A questão é que, de fato consegui com a lista o que eu queria, porém minha coluna não foi desejada, pois cada célula está a lista completa de valores, ao invés de distribuir cada item da lista para cada célula. Como podemos ver abaixo:
Então decida criar uma lista através de uma consulta, dessa forma:
= {List.Sum(Table.Column(#"Dados (2)", "1/1/2022")), List.Sum(Table.Column(#"Dados (2)", "2/1/2022 ")), List.Sum(Table.Column(#"Dados (2)", "3/1/2022")), List.Sum(Table.Column(#"Dados (2)", "4/1 /2022")), List.Sum(Table.Column(#"Dados (2)", "5/1/2022")), List.Sum(Table.Column(#"Dados (2)", "6 /1/2022")), List.Sum(Table.Column(#"Dados (2)", "7/1/2022")), List.Sum(Table.Column(#"Dados (2)", "01/08/2022")), List.Sum(Table.Column(#"Dados (2)", "01/09/2022")), List.Sum(Table.Column(#"Dados (2) ", "10/1/2022")), List.Sum(Table.Column(#"Dados (2)", "11/1/2022")), List.Sum(Table.Column(#"Dados ( 2)", "01/12/2022"))}
deu certo, conforme figura:
Porém não consigo da mesma forma importar valores para minha tabela, pois diz que são valores em formato 'text'. Alguém pode me ajudar?
Solved! Go to Solution.
Hi , @glatzmarcus
Hi , @glatzmarcus
According to your description, you have calculated the value by date as a value list in Power Query. And you want to add the list to each date as a column . Right?
Here are the steps you can refer to :
(1)This is my test data:
(2)Then we can create a blank quert and enter:
= Table.FromColumns({Table.ToColumns(Date){0},Table})
Then we can get your need:
If this method does not meet your needs, you can provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi , @glatzmarcus
Hi , @glatzmarcus
According to your description, you have calculated the value by date as a value list in Power Query. And you want to add the list to each date as a column . Right?
Here are the steps you can refer to :
(1)This is my test data:
(2)Then we can create a blank quert and enter:
= Table.FromColumns({Table.ToColumns(Date){0},Table})
Then we can get your need:
If this method does not meet your needs, you can provide us with your special sample data and the desired output sample data in the form of tables, so that we can better help you solve the problem.
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
100 | |
78 | |
76 | |
52 |
User | Count |
---|---|
144 | |
109 | |
108 | |
88 | |
61 |