Forum Discussion
Datamart - SQL query Editor
"Basically, i brought in a table, writing a sql query and would like to use the query to create the report."
OK, so what's the problem? If you've brought in a table into PBI Desktop or Online, then what keeps you from using it to create reports?
Hi what i mean is i have the table in powerbi, if i right a query for that table in sql, the new query i have created. how can i use it for the report. Normally i would do the query in sql management then bring the query in PowerBI to create the report. with the datamart now lettting us write query in sql. i was just wandering if i can use that query against a report.
- daXtreme3 years agoSolution Sage
I've never heard about anyone being able to run a SQL query against a report created in Power BI... SQL is for querying databases. DAX is for querying semantic models. Two very different things.
- KevinMorneault3 years agoHelper II
HI thanks for your reply.
Here's an example of what i am trying to do.
Actual Scenario
SQL Management - Table - Inventory
As an example, i have a table in MS SQl - i would write a sql query to clean my data and only bring or have want i need to create a report. Once Completed. Within Power BI i would connect to SQL and input my sql query i have created. Then create the dashboard.
Scenario 2
Datamart - SQL Editor
Here i connected to a ODATA connection. i have imported some table, once imported, using the slq editor, i would create a query the same way i did via the SQL Management. Once i am done with the query, am i able to use this query to create a dashboard.
- KevinMorneault3 years agoHelper II
Sorry forgot to ask.
If i can't do this, what is the need or purpose of having a sql editor in Datamart.
Also if not mistaken, with the ODATA file i would have imported the data in the datamart, i would be able to connect to a the SQL management by copying the code provided from the datamart and then i would suppose i would be able to write a sql query, then use that query for the dashboard in power bi. Does this make sense.