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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
AlessandroBet
Helper V
Helper V

Data refresh with CSV file

Hi,

 

i'm importing CSV file stored on google drive (ex: g:\database\CSV\test.csv) but when i refresh the data with PBI desktop it doesn't work.

I have already read all the similar post

 

Thanks

1 ACCEPTED SOLUTION

Removing the column parameter it works

View solution in original post

13 REPLIES 13
danextian
Super User
Super User

What does it show on the query editor preview? Try renaming the csv file and refresh again. If you don't get an error, you might be using a different file.





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.

I get error if i rename the file but if i rename back the data are not refreshed.

To read the correct data i have to import again the file in thr new query

Can you please post both queries? new and old.





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.

how can i post the query?

Right click  a query and then click advanced editor. Copy the code inside.

danextian_0-1738103661074.png

 





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.

let
    Source = Csv.Document(File.Contents("G:\Drive\File.csv"),[Delimiter=",", Columns=17, Encoding=65001, QuoteStyle=QuoteStyle.None]),
    #"Promoted Headers" = Table.PromoteHeaders(Source, [PromoteAllScalars=true])
in
    #"Promoted Headers"

Please post both codes - the old that didnt refresh and the new one.





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.

Both code are identical except the new query loads 20 columns and old one loads 17. (3 are those added). 

I did several text and i get the data refreshed only if i create a new query selecting the same file

I have changed the name of forlder and file

I have moved the folder locally

If i rename folder and file i get error

I have copied the query

I have refreshed on both the enviroments

 

I suppose it is a bug of PBI

Normally, when you connect to a csv file, the connector automatically specifies the number of columns. If in the next refresh, more columns added, only the the number of columns specified are picked by the query. That parameter is optinal though.





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.

Removing the column parameter it works

AlessandroBet
Helper V
Helper V

I dont get any error. Looks like it doesnt read the new data 

Hi @AlessandroBet ,

Make sure that you do not have any step applied that removes new data to be added in power query.

Maybe filters.

To debbug, refresh the data in power query and go to your applied steps and check from top to bottom to see in which step this data desappear.

because if you reload the data in diferent table, and all data come from the same file, that mean theres step that filter data in your original table.

Bibiano_Geraldo
Super User
Super User

Hi @AlessandroBet ,

Why its doesn't work? its giving you an error?

Please give us more details. whats happen when you click the refresh button?

 

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 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.

Top Solution Authors
Top Kudoed Authors