Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Call Server Name in OLE DB Query

Status
Not open for further replies.

mpm32

Technical User
Feb 19, 2004
130
US
Hi,

I have an Excel workbook that imports data from an Access query. This works fine on my PC. However when someone else goes to refresh the data, it will not work on their PC due to the drive mapped names are different.

I would like to call the server name instead of the drive letter. I have tried entering the server name in however I get an error.

This is the Query;

Code:
Provider=Microsoft.Jet.OLEDB.4.0;User ID=Admin;Data Source=Q:\Forecast\2009\data\FSS Financials.mdb;Mode=ReadWrite;Extended Properties="";Jet OLEDB:System database="";Jet OLEDB:Registry Path="";Jet OLEDB:Engine Type=5;Jet OLEDB:Database Locking Mode=1;Jet OLEDB:Global Partial Bulk Ops=2;Jet OLEDB:Global Bulk Transactions=1;Jet OLEDB:New Database Password="";Jet OLEDB:Create System Database=False;Jet OLEDB:Encrypt Database=False;Jet OLEDB:Don't Copy Locale on Compact=False;Jet OLEDB:Compact Without Replica Repair=False;Jet OLEDB:SFP=False

The server name looks like this - Uxxtm1-txxxx03\Shared-Data

When I replace "Q:" with Uxxtm1-txxxx03\Shared-Data I get this error;

'C:\Documents and Settings\xx123xx\My Documents\Uxxtm1-txxxx03\Shared-Data\Forecast\2009\data\FSS Financials.mdb is not a valid path. Make sure the path name is spelled correctly........

Not sure why it's pointing to my C:\ drive.

Any thoughts?

Thanks - in advance.
 
Uxxtm1-txxxx03\Shared-Data

needs to be:

\\Uxxtm1-txxxx03\Shared-Data

I'm pretty certain.

Also, you can try looking at

For various examples in case that helps.

--

"If to err is human, then I must be some kind of human!" -Me
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top