How to Connect Redshift to Power BI in PostgreSQL

Galaxy Glossary

How do I connect Amazon Redshift to Power BI?

Connect Amazon Redshift to Microsoft Power BI to visualize and analyze your Redshift data in real time.

Sign up for the latest in SQL knowledge from the Galaxy Team!

Description

How do I connect Power BI to Amazon Redshift?

In Power BI Desktop, click Get Data → Amazon Redshift. Paste the Redshift endpoint in the format redshift-cluster.abc123.us-east-1.redshift.amazonaws.com:5439, supply the database name, choose Import or DirectQuery, and press OK.Enter your Redshift username and password, pick a schema, check the desired tables, and load the data.

What prerequisites must be ready?

Make sure the Redshift security group allows inbound traffic from your workstation’s IP on port 5439, the redshift:GetClusterCredentials action is permitted (if IAM authentication is used), and the Power BI On-Premises Data Gateway is installed for scheduled refreshes.

Which connection mode should I pick?

Import copies data into Power BI for fastest visuals but uses memory and requires refresh jobs.DirectQuery keeps data in Redshift and sends SQL on every interaction—ideal for near-real-time dashboards but relies on cluster performance.

How do I write custom SQL in Power BI?

In the navigator, click Transform Data → Advanced Editor and replace the autogenerated query with your own, or select the SQL statement option during connection to paste a handcrafted query.

Best practices for speed?

Choose varchar lengths wisely, sort keys on common filters, add dist keys on large fact tables, limit imported columns, and aggregate in SQL before Power BI.Use Import for small, wide tables and DirectQuery for large, narrow tables.

.

Why How to Connect Redshift to Power BI in PostgreSQL is important

How to Connect Redshift to Power BI in PostgreSQL Example Usage


SELECT c.name, o.order_date, o.total_amount
FROM Customers c
JOIN Orders o   ON o.customer_id = c.id
WHERE o.order_date >= '2024-01-01'
ORDER BY o.order_date DESC;

How to Connect Redshift to Power BI in PostgreSQL Syntax


ODBC connection string syntax:
Driver={Amazon Redshift (x64)};Server=redshift-cluster.abc123.us-east-1.redshift.amazonaws.com;Port=5439;Database=ecommerce;UID=<username>;PWD=<password>;SSL=true;

Common Mistakes

Frequently Asked Questions (FAQs)

Can I use IAM credentials instead of a password?

Yes. Select Use my current credentials in Power BI and grant redshift:GetClusterCredentials and redshift:JoinGroup permissions to your IAM role.

How do I schedule data refreshes?

Publish the report to Power BI Service, install the On-Premises Data Gateway, and configure refresh cadence under Datasets → Settings.

Want to learn about other SQL terms?

Trusted by top engineers on high-velocity teams
Aryeo Logo
Assort Health
Curri
Rubie
BauHealth Logo
Truvideo Logo