Join 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!The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!
Hi Everyone,
I was trying to connect to one of SQL server, where i couldn't reach out it through power Bi desktop. In my local IDE i could retrive data from same SQL source. In other way i retrived the data from power bi and up on again i tried python script but it seems again same error. Can some one hel me out why it's happening.
Script:
import pyodbc
conn = pyodbc.connect('Driver={SQL Server};'
'Server=server_name;'
'Database=db_name;'
'Trusted_Connection=yes;')
cursor = conn.cursor()
cursor.execute('SELECT * FROM db_name.Table')
Error:
Hi @DineshGedda ,
The file or directory is corrupted and unreadable I'm not so sure why you not use sql connector to get data, it also allow you to use t-sql query as additional parameter to sql database.
For your issue, I'd like to suggest you to check firewall settings and network policy to confirm if your request has been blocked.
Regards,
Xiaoxin Sheng
Hi @Anonymous , Thanks for your response, but it didn't worked.
The Power BI Data Visualization World Championships is back! It's time to submit your entry.
| User | Count |
|---|---|
| 50 | |
| 43 | |
| 36 | |
| 33 | |
| 30 |
| User | Count |
|---|---|
| 138 | |
| 125 | |
| 60 | |
| 59 | |
| 56 |