Relative Folder Path: Power Query Guide

  Рет қаралды 2,621

How to Learn Excel

How to Learn Excel

Күн бұрын

Пікірлер: 13
@abbadq
@abbadq 4 ай бұрын
👍 key point to knowledge.
@howtolearnexcel
@howtolearnexcel 4 ай бұрын
Thank you!
@FsoOmar
@FsoOmar 3 ай бұрын
Great Tip! Thank you.
@howtolearnexcel
@howtolearnexcel 3 ай бұрын
Yeah, saves some time. I wish it were added as an native option in PQ. Thank you!
@omarnader776
@omarnader776 5 ай бұрын
Great
@howtolearnexcel
@howtolearnexcel 5 ай бұрын
Thank you! So glad it's helpful!
@constantsignals4474
@constantsignals4474 2 ай бұрын
works perfect for local files/folders. but does not work for me when moving the folder to onedrive/sharepoint. any suggestions?
@howtolearnexcel
@howtolearnexcel 2 ай бұрын
Interesting question. I need to research it a bit. By the way, do you mean a personal OneDrive or OneDrive for Business? As for SharePoint, you should check this video: kzbin.info/www/bejne/o5i5n55qh5xsl8U P.S. I'll try to find the solution and answer a bit later.
@constantsignals4474
@constantsignals4474 2 ай бұрын
@@howtolearnexcel thanks for linking the sharepoint video. I was talking bout OneDrive for business. In our company it often happens that people do some analysis local and then want to share it with onedrive or sharepoint. the static paths always break
@howtolearnexcel
@howtolearnexcel 2 ай бұрын
I can confirm that this is possible. But it is a bit tricky. For example, to connect to your own Business OneDrive directory, you need to get this part of the address: comapanyname-my.sharepoint.com/personal/login/ (and delete everything else). If your consolidation file is placed there too, you can use the formula to grab the part before the 5th slash. Like this: =LEFT(CELL("filename",A1), FIND("#", SUBSTITUTE(CELL("filename",A1), "/","#", 5))) Then place it in the "Table1" - "Path" column. The PQ code will be following: let Source = SharePoint.Contents(Excel.CurrentWorkbook(){[Name="Table1"]}[Content]{0}[Path], [ApiVersion = 15]), Documents = Джерело{[Name="Documents"]}[Content]{[Name="SubfolderName"]}[Content] in Documents The first line grabs the relative path. The second is where you define the subfolder (as many levels as needed). You can use SharePoint.Contents or SharePoint.Files function depending on what you need. If you want, you can modify your code to work with local files and the SP\OneDrive. To do this, you can simply use: if Text.StartsWith(Excel.CurrentWorkbook(){[Name="Table1"]}[Content]{0}[Path],"http") then (code above) else (code from my video). The same works with other "common" SP folders as well if you have access. P.S. Here is one more Wyn's video on this topic with more in depth explanation: kzbin.info/www/bejne/Y4moaHt7j8eEn7s
@Prafful000
@Prafful000 Күн бұрын
Very Nice hack... It would have been great only if you spoke better english for me to understand 😢
@howtolearnexcel
@howtolearnexcel Күн бұрын
Thanks for the feedback! I’m sorry if my English made it a bit hard to understand. I’ll do my best to improve, step by step! Hopefully, the latest videos will be easier to follow. Appreciate your patience!
@Prafful000
@Prafful000 Күн бұрын
@howtolearnexcel Once again Thank you for this game changer excel hack... Will watch the video a couple of times more and learn it 👍
How to Import data from a folder with multiple files - Power Query
1:41
How to Learn Excel
Рет қаралды 1,1 М.
How to create a relative file path in Power Query
5:59
Excel TV
Рет қаралды 41 М.
UFC 310 : Рахмонов VS Мачадо Гэрри
05:00
Setanta Sports UFC
Рет қаралды 1,2 МЛН
Power Query - Avoid "Helper Queries" (+10 Cool Tricks)
18:40
7 Power Query Tricks You’ll Regret Not Knowing
24:05
Goodly
Рет қаралды 20 М.
Excel Data Cleaning 101: Fix Common Data Problems
2:44
How to Learn Excel
Рет қаралды 2,4 М.
Jensen Huang Said Nvidia Will Hit $2000 | NVDA Stock Latest News
17:50
Lion Of Wall Street
Рет қаралды 7 М.
Create a Dynamic File Path in Power Query
13:18
Goodly
Рет қаралды 98 М.