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

The Power BI Data Visualization World Championships is back! It's time to submit your entry. Live now!

Reply
Muhammadirfan20
Frequent Visitor

Data loading issue_CSV_XLX

Muhammadirfan20_0-1762517312475.pngMuhammadirfan20_1-1762517347157.png

Muhammadirfan20_2-1762517549697.png

Hi community! I am learning Power BI. I am facing issue for loading data. Direct loading is not supported, when i click on "Transform data" it opened, and i clean it, after that, when i click on apply, error showed there on main interface, all the screemshots are attached. Please help to get rid of this problem. Thank you for your cooperation

 

1 ACCEPTED SOLUTION
v-tejrama
Community Support
Community Support

Hi @Muhammadirfan20 ,

 

The issue you’re facing isn’t with the CSV or Excel data itself but with how Power BI is trying to load it The error message “We couldn’t connect to your DirectQuery data source or internal model” appears because Power BI is attempting to treat a flat file CSV or Excel as a DirectQuery source which isn’t supported Flat files only work in Import mode meaning Power BI must fully load the data into the model before visuals can use it.

 

To fix this reconnect your file using Import mode In Power BI Desktop go to Home Get Data TextCSV or Excel Workbook select your file and click Load or Transform Data This automatically uses Import mode Perform your transformations in Power Query and then click Close & Apply to load the data If you previously connected the file through a DirectQuery path such as a dataflow SQL source or SharePoint delete that query and reconnect directly to the file in Import mode.

 

Also check your file extension If the file ends with “xlx” instead of “xlsx” Power BI may not recognize it as a valid Excel format Open it in Excel use File Save As choose Excel Workbook xlsx and reconnect to the new file.

 

If the problem continues after reconnecting review the steps in Power Query Sometimes the “Changed Type” autostep causes loading errors Open Power Query Editor remove the “Changed Type” step and manually set the data types for each column If errors appear in any column rightclick it choose Replace Errors and replace them with null

For CSV files check encoding and delimiters In Power Query click the gear icon next to the Source step and verify the delimiter comma or semicolon and file origin set to UTF8 if needed.

 

Finally make sure the file isn’t open in Excel while loading update Power BI Desktop to the latest version and clear permissions from File Options and settings Data source settings Clear permissions before reconnecting

After reconnecting the file using Import mode and verifying that the format is correct the “Something went wrong” or “DirectQuery data source” error will no longer appear.

Thank you.

 

View solution in original post

6 REPLIES 6
v-tejrama
Community Support
Community Support

Hi @Muhammadirfan20 ,

 

The issue you’re facing isn’t with the CSV or Excel data itself but with how Power BI is trying to load it The error message “We couldn’t connect to your DirectQuery data source or internal model” appears because Power BI is attempting to treat a flat file CSV or Excel as a DirectQuery source which isn’t supported Flat files only work in Import mode meaning Power BI must fully load the data into the model before visuals can use it.

 

To fix this reconnect your file using Import mode In Power BI Desktop go to Home Get Data TextCSV or Excel Workbook select your file and click Load or Transform Data This automatically uses Import mode Perform your transformations in Power Query and then click Close & Apply to load the data If you previously connected the file through a DirectQuery path such as a dataflow SQL source or SharePoint delete that query and reconnect directly to the file in Import mode.

 

Also check your file extension If the file ends with “xlx” instead of “xlsx” Power BI may not recognize it as a valid Excel format Open it in Excel use File Save As choose Excel Workbook xlsx and reconnect to the new file.

 

If the problem continues after reconnecting review the steps in Power Query Sometimes the “Changed Type” autostep causes loading errors Open Power Query Editor remove the “Changed Type” step and manually set the data types for each column If errors appear in any column rightclick it choose Replace Errors and replace them with null

For CSV files check encoding and delimiters In Power Query click the gear icon next to the Source step and verify the delimiter comma or semicolon and file origin set to UTF8 if needed.

 

Finally make sure the file isn’t open in Excel while loading update Power BI Desktop to the latest version and clear permissions from File Options and settings Data source settings Clear permissions before reconnecting

After reconnecting the file using Import mode and verifying that the format is correct the “Something went wrong” or “DirectQuery data source” error will no longer appear.

Thank you.

 

Hi @Muhammadirfan20 ,

 

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions

Thank you.

Hi @Muhammadirfan20 ,

 

I wanted to follow up and see if you had a chance to review the information shared. If you have any further questions or need additional assistance, feel free to reach out.

 

Thank you.

Muhammadirfan20
Frequent Visitor

Did not get solution yet 

 

grazitti_sapna
Super User
Super User

Hi @Muhammadirfan20,

What is the source of excel you are loading?

Some connectors (like Web, OData, Google Sheets, API endpoints, Oracle Fusion, etc.) do not support DirectQuery, only Import mode.

 

In Power BI Desktop:
Home → Get Data → (your source)
When prompted, select Import instead of DirectQuery.

 

Also check that the credential and connector information is correct.

 

🌟 I hope this solution helps you unlock your Power BI potential! If you found it helpful, click 'Mark as Solution' to guide others toward the answers they need.
💡 Love the effort? Drop the kudos! Your appreciation fuels community spirit and innovation.
🎖 As a proud SuperUser and Microsoft Partner, we’re here to empower your data journey and the Power BI Community at large.
🔗 Curious to explore more? [Discover here].
Let’s keep building smarter solutions together!

danextian
Super User
Super User

Hi @Muhammadirfan20 

CSV, Excel files and other flat files do not support direct query but import mode only.





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! It's time to submit your entry.

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

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.