0

I need help to understand a problem regarding a set of power queries that was written by a former colleague of mine.

I have very basic knowledge of power query but intermediate understanding of scripting in general. A previous colleague of mine produced a calculation tool in excel with some power queries that read data from an .csv file and then perform some operations on the data.

The .csv file is fetched from an api. I Have used postman to fetch the data earlier and this works hassle-free. But now when I fetch the data with Unirest I get the same .csv file but when I try to update the calculation tool I get an expression error saying it cant find a specific column even though the column its complaining about is actually there.

I don’t understand why I get error when I use one method of fetching the data but not when I use the other. The .csv files are seemingly identical.

When I open the query editor the error is appointed to a step called “changed type” so I thought that there was some kind of difference in datatypes in the .csv files. But when I use the built-in functions in excel to check for datatypes in the .csv files all columns and rows return the same result.
Can someone give me a hint here on what might be going on?

Christian Baumann
  • 3,188
  • 3
  • 20
  • 37
Alfonso
  • 21
  • 6
  • 1
    The changed type step is looking for a column name that is not present (based on previous steps). Check each step in turn starting from the beginning to make sure that the csv is being parsed correctly. I suspect it isn't. – Rory Jul 14 '22 at 11:55
  • Look for ,Columns=12, or similar in the first step, and remove that part in case there are different column numbers in each file. Then do what Rory suggested and look for changed column names. – horseyride Jul 14 '22 at 13:08

0 Answers0