Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
wshalex123
Helper III
Helper III

Run a query against a dataset, create .csv

 
Hey,

... i didn't get any help in the Power Automate community, so i'll try it here:

 

Whereever i look, this should work for everyone accept me haha. I Just want to get a .csv table out of my PowerBI table.

 

i got a flow where i a table out of my Power BI report and save it as a .csv in a Sharepoint  folder. 

 

wshalex123_4-1668096996580.png

This is my query text:

DEFINE
VAR _ma1 =
SUMMARIZECOLUMNS(
"Urlaub", SUM(PersonnelManagement_EmployeeDayBalances[Offene Urlaubsstunden]),
"Zeitausgleich", SUM(PersonnelManagement_EmployeeDayBalances[Offener Zeitausgleich])
)
EVALUATE
_ma1

 

 

Results of the flow:

 
wshalex123_5-1668097019630.png

 

Question:

Why doesn't it seperate it in two columns? Instead, it seperates the entries with a comma ","

In DAX editor it's seperating the results in 2 columns, like i'd wish it to be in my .csv file.

 

wshalex123_6-1668097036931.png

What am i doing wrong?

Would be happy if someone can help me out. 🙂 

5 REPLIES 5
ImkeF
Community Champion
Community Champion

I support what @jbwtp  suggested.

 

Imke Feldmann (The BIccountant)

If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!

How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries

ImkeF
Community Champion
Community Champion

Hi @wshalex123 ,
csv is a comma separated text format, so the result looks as expected to me.
When openening it in Excel, you can split it by this delimiter: Go to DAta -> Data Tools -> Text to Columns 
and then choose the comma as a separator.
Or open it via Power Query, that's a bit more reliable.

Imke Feldmann (The BIccountant)

If you liked my solution, please give it a thumbs up. And if I did answer your question, please mark this post as a solution. Thanks!

How to integrate M-code into your solution -- How to get your questions answered quickly -- How to provide sample data -- Check out more PBI- learning resources here -- Performance Tipps for M-queries

Hey @ImkeF,

 

thanks you for your response. 

 

Iam deleting this file once per day and save it again there via this flow, so a Solution in Power querry would be fitting more in my case.

 

Can you help me with this? 🙂 Or do you have any other idea how i could automattically export the table from Power BI in another table or make in change it in one?

 

Thanks a lot. 

 

Cheers, Alex

Hi @wshalex123,

 

I think what Imke is suggesting is to import the csv file that you create using the Automation via Power Query in Excel.

jbwtp_0-1668115863708.png

 

on the Data tab in the Excel's main menu.

 

P.S. Sorry, in your case this is of course would be another connector - Sharepoint Folder - but the idea remains the same.

 

 

This way you can then import it from PQ to one of the tabs in the Excel workbook as a table and then just refresh when required.

 

Cheers,

John

jbwtp
Memorable Member
Memorable Member

Just giving it another thought: if you still put the data back to Excel, do you want to consider using Analyse in Excel funcionality? This may be a simpler solution, this way you can import data without using Automate and csv as an intermediaries.

 

Regards,

John 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.

Top Solution Authors
Top Kudoed Authors