Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin 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.
can I run a sql query against data imported into the semantic model in power bi desktop
Solved! Go to Solution.
Hi @djm7 ,
The short answer is no, you can't query model data using SQL within Power BI Desktop. PBI models use the tabular structure and are optimised for DAX and MDX queries.
However, depending on your use-case, you may be able leverage Datamarts, but you've not provided enough information to understand whether this is feasible/appropriate or not:
https://learn.microsoft.com/en-us/power-bi/transform-model/datamarts/datamarts-analyze
Pete
Proud to be a Datanaut!
No, you cannot run SQL queries directly on imported data in Power BI’s semantic model. Instead:
No, you cannot run SQL queries directly on imported data in Power BI’s semantic model. Instead:
Hi @djm7 ,
The short answer is no, you can't query model data using SQL within Power BI Desktop. PBI models use the tabular structure and are optimised for DAX and MDX queries.
However, depending on your use-case, you may be able leverage Datamarts, but you've not provided enough information to understand whether this is feasible/appropriate or not:
https://learn.microsoft.com/en-us/power-bi/transform-model/datamarts/datamarts-analyze
Pete
Proud to be a Datanaut!
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.