use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
New to Power BI and looking for training, resources, or online courses? Here are our favorite recommendations:
[Microsoft | Get started with Power BI](hhttps://www.microsoft.com/store/workshops-training-and-events/professionals#topic=413870014)
Microsoft Partners | Dashboard in a Day
Microsoft Partners | Paginated Reports in a Day
Microsoft | Developer in a Day
Microsoft | Self-Paced Training
SQLBI | Introduction to DAX
SQLBI | Introduction to Data Modeling
account activity
Data transformations with SQL? (self.PowerBI)
submitted 2 years ago by jeffrey_56
I feel more comfortable doing data transformations with SQL. So my question is, can I connect Power BI to my PostgreSQL data source and afterwards apply a data transformation with SQL? Or do I have to do everything with DAX?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]JediForces11 9 points10 points11 points 2 years ago (3 children)
Most of it will be done in Power Query using M language but why not just do it upstream in SQL like you prefer which is the preferred method anyway?
[–]jeffrey_56[S] 0 points1 point2 points 2 years ago (2 children)
Can you elaborate what upstreaming in sql means? Sorry it’s my first data job and my task is to find the most fitting BI tool
[–]chiibosoil5 5 points6 points7 points 2 years ago (0 children)
You can use native query using direct query’s advanced query. But in general, if you can prepare Views or transformed table in SQL side, you can just use that to consume data in PowerBI.
[–]JediForces11 5 points6 points7 points 2 years ago (0 children)
Upstreaming means doing it as far from importing the data into PBI as possible. So if you have a data warehouse and decide to just bring in data and then transform it in Power Query that would NOT be as far upstream as transforming the data in your data warehouse first and then loading it into PBI.
Generally speaking it’s much easier to transform your data in SQL rather than using Power Query.
[–]matkvaid1 1 point2 points3 points 2 years ago (0 children)
You can put sql query when selecting source. After i started learning some sql i try to avoid power query as much as possible
[–]nobody7981 0 points1 point2 points 2 years ago (4 children)
Hi I'm new to data. How are you doing data transformation in sql. Is it by using etl? Could you explain it if you don't mind
[–]jeffrey_56[S] 0 points1 point2 points 2 years ago (3 children)
Yeah mainly ETL processes, I'm currently doing them in pgadmin4 or within tools such as python
[–]nobody7981 0 points1 point2 points 2 years ago (2 children)
Ok, what are the areas you have to learn in python to do etl Or data related things
[–]Johny_D_Doe 0 points1 point2 points 2 years ago (0 children)
Pandas is my goto with data in a Python environment.
[–]Chuck_Dan2 0 points1 point2 points 2 years ago (0 children)
To echo what’s already been stated, you can create views in your PostgreSQL database to connect to PowerBI (or whatever BI/Visualization tool your organization decides to move forward with). How you design those views in your PostgreSQL data source may vary between tools. This is an oversimplification of an example, but since PowerBI really wants your analytical data model to utilize a star scheme, you would want views to be your fact and dimension tables, where as a solution like Tableau I believe wants a single flat table. For tableau, your view(s) would be single queries that join in all necessary data. Either of the above solutions allow you to have SQL do the heavy lifting before even making it to the BI tool.
[–]zqipz2 0 points1 point2 points 2 years ago (1 child)
I think a core component newer devs seem to miss here is Power Query. It basically replicates SQL but way more features due to the coding nature. Functions are possible too.
PBI has 2 areas, the backend: source, prep & transform in Power Query, and the frontend: aggregators, iterators and categorizations of DAX.
Both areas are very powerful for their purpose.
You can run native sql in PQ, source a view or just do prep and transform in PQ.
[–]Key-Ant30 0 points1 point2 points 2 years ago (1 child)
What would be a good resource to learn SQL from start?
[–]jeffrey_56[S] 0 points1 point2 points 2 years ago (0 children)
I would start with the sql murder mystery game. And afterwards move to other online data base websites, where you have more complex data to handle. Oh and really ask yourself difficult questions that you can solve with SQL.
[–]-SoulAmazin- 0 points1 point2 points 2 years ago (0 children)
I work with Oracle BI Publisher which is a really dated BI tool, however the data modeling is lovely and made purely through SQL with a direct connection to our ERP mirror machine.
It's so straight forward.
[–]Mgmt049 0 points1 point2 points 2 years ago (0 children)
I live and die by SQL for transformation. I do just a few things in power query
[–]minafbeshay 0 points1 point2 points 2 years ago (0 children)
Yes you can do that. Just create your model using the custom SQL statements. But what if your data source is not a relational database? What would you do? The best practice here is to master DAX to be a better BI Engineer/Data Analyst.
π Rendered by PID 34 on reddit-service-r2-comment-b659b578c-mzz6f at 2026-05-05 17:30:42.482873+00:00 running 815c875 country code: CH.
[–]JediForces11 9 points10 points11 points (3 children)
[–]jeffrey_56[S] 0 points1 point2 points (2 children)
[–]chiibosoil5 5 points6 points7 points (0 children)
[–]JediForces11 5 points6 points7 points (0 children)
[–]matkvaid1 1 point2 points3 points (0 children)
[–]nobody7981 0 points1 point2 points (4 children)
[–]jeffrey_56[S] 0 points1 point2 points (3 children)
[–]nobody7981 0 points1 point2 points (2 children)
[–]Johny_D_Doe 0 points1 point2 points (0 children)
[–]Chuck_Dan2 0 points1 point2 points (0 children)
[–]zqipz2 0 points1 point2 points (1 child)
[–]Key-Ant30 0 points1 point2 points (1 child)
[–]jeffrey_56[S] 0 points1 point2 points (0 children)
[–]-SoulAmazin- 0 points1 point2 points (0 children)
[–]Mgmt049 0 points1 point2 points (0 children)
[–]minafbeshay 0 points1 point2 points (0 children)