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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
AnibalPb
Frequent Visitor

Cannot connect to MySQL database

Hi, I'm having a problem connecting Power BI to a MySQL DB. I'm connecting to localhost and then select the database 'monitore_perfileducacion'. I don't know why but this error comes up when it appears everything's alright. And if I try to connect to the IP that appears at the workbench connections in MySQL it doesn't work. How can I fix this? I tried everything in almost every available post.

 

DataSource.Error: MySQL: Authentication to host 'localhost' for user 'root' using method 'caching_sha2_password' failed with message: Unknown database 'monitore_perfileducacion'
Details:
DataSourceKind=MySql
DataSourcePath=localhost;monitore_perfileducacion
Message=Authentication to host 'localhost' for user 'root' using method 'caching_sha2_password' failed with message: Unknown database 'monitore_perfileducacion'
ErrorCode=-2147467259

 

The screen looks like this, and if I press refresh in the preview, the error is shown. Thing is, the connection is alright in MySQL.

 

Duda Power BI community.png

 

 

Duda Power BI community (1).PNGDuda Power BI community (2).PNG

1 ACCEPTED SOLUTION
v-yuta-msft
Community Support
Community Support

@AnibalPb ,

 

This error message means your root name or password is incorrect. Please check them again in mysql database.

 

Regards,

Jimmy Tao

View solution in original post

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

@AnibalPb ,

 

This error message means your root name or password is incorrect. Please check them again in mysql database.

 

Regards,

Jimmy Tao

Hi Everyone,

 

Someone could solve this because it is also happening to me with the same error message.

 

Thanks.

Hi Jimmy,

I had the same issue. I'm pretty sure the username and password is correct (I can log in into workbench with same credentials)I also tried clear permission and reconnect again, still doesn't work. Do you have other suggestions?

 

 

Thanks,

Vicky

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.