I can however list the tables…
If I run Exec sp_tables_ex 'LSTest'
I get a result with a list of tables.
But if I run
Exec sp_columns_ex 'LSTest', '<one of those table names>'
I get an empty list, and if I try to query them I also get nothing.
If I go into the properties of the Linked Server I have the Be made using this security context
and I use the Remote login:
and With password:
for the workgroup file that I would normally use in MS Access.
If I try to script a query by right clicking the table name in the linked server, instead of a select statement I get the following:
-- [LSTest]...[Tablename] contains no columns that can be selected or the current user does not have permissions on that object.
Best Answer
1. Set your SystemDB File in the Registry
Note that you can only specify ONE of these damn things.
On 32-bit Windows
If your Windows installation on which your SQL Server instance installed is 32-bit which is doubtful...use the following key to set the path to your MS-Access Workgroup file (
*.mdw
):HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Jet\4.0\Engines\SystemDB
On 64-bit Windows
On the other hand if your Windows installation on which your SQL Server Instance is installed, is 64-bit, (more likely) set the path to your MS-Access Workgroup file (
*.mdw
) here:HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Jet\4.0\Engines\Jet 4.0\Engines\SystemDB
2. Create your linked server to MS Access
3. Make sure that your database credentials are passed to the Workgroup File
(.mdw)
when running a query from the(.mdb)
Now if you want to make sure that the password is being passed correctly after running this....in the
Object Explorer
panel, in<server-name>\Server Objects\Linked Servers
, right click it and clickrefresh
...your newLinkedServerToMSAccessMDB
should now appear in the list, right click it and selectProperties
In the window that appears next in the
Select a page
panel, clickSecurity
and then in theFor a login no defined in the list above, connections will:
radio button list, select theBe made using this security context:
(if you don't want to be particular about what network users have access to it....otherwise use the mappings) and then in enter the username and password you would normally use to access MS Access using your.mdw
file in theRemote login:
andWith password:
text boxes.4. Run a Query
After you click
OK
you should now be able to run aselect
on the.mdb
file so that you can create aVIEW
in a schema for some specified user.