mikemck
New member
- Joined
- Jan 14, 2019
- Messages
- 18
- Reaction score
- 0
- Points
- 0
- Excel Version(s)
- 2016
I just had a serious revelation. I've been viewing the advanced editor and studying the M code there, and I get overwhelmed and discouraged at the complexity of the coding.
I realized that viewing the applied steps themselves, just in the formula bar, is a completely different experience and much easier to understand.
As an example, I had a query where I was getting the formula firewall error and solved it by bringing the files into my parameter query.
In my parameter query, I used drill down on the parameter, added a custom step and wrapped what was displayed in File.Contents.
Clicking the fx to add a custom step resulted in this in the formula bar: = #"Forecast File Folder & Name"
All I did was wrap that like this: File.Contents("Forecast File Folder & Name")
Voila, my files are now landed in my parameter query.
Looking at the advanced editor, this is what I see : Custom1 = Excel.Workbook(File.Contents(#"Forecast File Folder & Name"), null, true)
Well damn, that's a lot more complex than what I wrote. I started reviewing more queries and just the applied steps and using the gear icon to see what was done, and I'm actually thinking that maybe I can get to a point where I might be able to actually use some M code if I need to in cases where the UI is enough.
I realized that viewing the applied steps themselves, just in the formula bar, is a completely different experience and much easier to understand.
As an example, I had a query where I was getting the formula firewall error and solved it by bringing the files into my parameter query.
In my parameter query, I used drill down on the parameter, added a custom step and wrapped what was displayed in File.Contents.
Clicking the fx to add a custom step resulted in this in the formula bar: = #"Forecast File Folder & Name"
All I did was wrap that like this: File.Contents("Forecast File Folder & Name")
Voila, my files are now landed in my parameter query.
Looking at the advanced editor, this is what I see : Custom1 = Excel.Workbook(File.Contents(#"Forecast File Folder & Name"), null, true)
Well damn, that's a lot more complex than what I wrote. I started reviewing more queries and just the applied steps and using the gear icon to see what was done, and I'm actually thinking that maybe I can get to a point where I might be able to actually use some M code if I need to in cases where the UI is enough.