
Announcements
I'm working on a flow which I need to get data from an excel table through expression. I am using a Compose (that I call 'Object') to track the ID of an 'Apply to Each' loop interaction and the data, and I can get the data quite well using 'outputs('Object')['Data']['Header']'. This is working perfectly.
However, some of the headers on the Excel file I'm reading have line break and that's something I cannot change on the Excel file myself. This is leading to errors while reading the header as it says that's not a valid property. I have to find a way to add the line break on the expression so the flow understands that's not only a space, but a line break space.
I tried adding \r, \n, <br>, <br /> copying the actual break line space from a dynamic content, but nothing works, it always gives me the same error.
The error it gives trying to use with the space:
The Excel file heading:
How it's written:
After searching for different queries on the internet, I came across this page which has some possible solutions. One of them being the use of the concatenate method with the code decodeUriComponent('%0A') in where the line break would be on my Excel header. That's the unicode for a breakline, it seems. And that actually worked!
My final expression now looks like: 'outputs('Object')['Data'][concat('Job',decodeUriComponent('%0A'),'Title')]' and returns the desired information.