The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi, I have an Excel sheet and using Power Query to pull in data from an MS Access database. I build the sheet on my desktop and now want to use it on my shared drive. In "Applied Steps" I go to "source" and changed the following in the editor:
("C:\Users\myname\Desktop\filename.accdb")
to
("G:\My Drive\folder\sub-folder\subfolder\filename.accdb").
However, the change of the path is giving me the following error message: I am not sure why I am getting this message because all my other sheets use the path on my shared drive.
Please can you help?
Thanks,
Nav
Hi @naveen73
I use below code to connect to an accdb file in a network shared folder and it works. Try if this works for you.
let
Source = Access.Database(File.Contents("\\servername\xxxx\xxxx\Test\Database1.accdb"), [CreateNavigationProperties=true]),
_Table1 = Source{[Schema="",Item="Table1"]}[Data]
in
_Table1
You could also create a new query and use Access connector to connect to the accdb file. Then open this new query's Advanced Editor and copy its path there. Use this path to replace that in old queries.
Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.
You likely need to use this syntax to get to your network share. Look at the mapping for your G drive to get it.
\\server\share\folder\subfolder
Pat
Can you share your whole query code (copy and paste it from the Advanced Editor)?
Hi,
Please see the code below (sorry, been trying to edit it but the functionality won't let me use the code style):
let
Source = Access.Database(File.Contents("C:\Users\NavGanpat\Desktop\FILENAME.accdb"), [CreateNavigationProperties=true]),
_Blotter = Source{[Schema="",Item="XXX"]}[Data],
#"Filtered Rows2" = Table.SelectRows(XXX, each true),
#"Removed Columns" = Table.RemoveColumns(#"Filtered Rows2",{"XXX"}),
#"Merged Queries" = Table.NestedJoin(#"Removed Columns", {"XXX"}, XXX, {"XXX"}, "XXX", JoinKind.LeftOuter),
#"Expanded Static" = Table.ExpandTableColumn(#"Merged Queries", "XXX", {"XXX"}),
#"Removed Columns1" = Table.RemoveColumns(#"Expanded Static",{"XXX", "XXX"}),
#"Filtered Rows" = Table.SelectRows(#"Removed Columns1", each [XXX] < #datetime(2021, 10, 1, 0, 0, 0))
in
#"Filtered Rows"
Thanks,
Naveen