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

Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.

Reply
wokka
Helper IV
Helper IV

Automated extract from datawarehouse - possible?

Hi

 

I'm new-ish to powerbi so please excuse if this is a basic question.  

 

We have an existing data warehouse. In powerbi when we query the data warehouse, we curently manually create a table and  drag in 4 dimensions. Then we do a manual extract of data, out into a csv file.

 

My question is can we write DAX code ( or similar ) to do that extraction, and do you have to manually run the DAX inside powerbi or can we kick it off from a command line or python or a powerbi server etc?

 

I'm starting off by thinking about this at a high level/concept level, then will drill down into the technical,  if this approach is  possible.

 

Thanks in advance.

1 ACCEPTED SOLUTION
Anonymous
Not applicable
5 REPLIES 5
wokka
Helper IV
Helper IV

Hi,

 

Thanks everyones responses so far

 

So what we have is a powerbi pbix  file that connects to an existing powerbi sematic model.

 

What I do currently is manually drag in 4 dimensions into a table to use the relationship between them to find one component of the data ( our internal Reference ID ), then extract the data out to disk in csv form using "Export data".

 

wokka_1-1739143312123.png

 

 

wokka_2-1739143542303.png

 

I guess we could do it all via TSQL code via the database backend , however all the hard work to develop the data relationships already exists in the semantic model.

 

Maybe this is the long way around, but its the only way that we know how to do it right now  ( I'm newish to powerbi so ....) but there must be a way to avoid manual manipulation , and maybe create like a virtual table via DAX commands ( or similar ) then extract the data out from that somehow? 

 

Thanks in advance, the fabric forum people are very helpful.    🙂

Anonymous
Not applicable

Correct, the best way is to run a DAX query against that semantic model with all the required columns. Then save the query results as CSV if you must 

NandanHegde
Super User
Super User

Can you be a bit more clear with your ask?
Is your final aspect to generate a CSV file? Then you can use data pipelines to directly create a file from fabric warehouse itself. no need of having a Power BI report created just for that purpose.




----------------------------------------------------------------------------------------------
Nandan Hegde (MSFT Data MVP)
LinkedIn Profile : www.linkedin.com/in/nandan-hegde-4a195a66
GitHUB Profile : https://github.com/NandanHegde15
Twitter Profile : @nandan_hegde15
MSFT MVP Profile : https://mvp.microsoft.com/en-US/MVP/profile/8977819f-95fb-ed11-8f6d-000d3a560942
Topmate : https://topmate.io/nandan_hegde
Blog :https://datasharkx.wordpress.com
lbendlin
Super User
Super User

You can access a data warehouse via its SQL Endpoint (for example). You can run custom SQL in your Power Query code.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.