MS Access - 链接到另一个Access数据库中的查询

时间:2022-12-21 15:38:29

How can I link query from another MS Access database? I know I can easily link tables, But I don't know how to link queries. The query takes data from many tables which I don't want to link.

如何链接来自另一个MS Access数据库的查询?我知道我可以轻松链接表格,但我不知道如何链接查询。查询从许多表中获取数据,我不想链接。

2 个解决方案

#1


15  

You can do it this way:

你可以这样做:

SELECT [RemoteQueryname].* FROM [RemoteQueryname] IN 'C:\RemoteDatabase.mdb'

I have tested with databases locally on my machine and runs flawlessly. The only note I would like to point out is before running the query check to make sure the remote databse is closed or it will crash the one trying to do the query.

我在我的机器上本地测试了数据库并运行完美。我想指出的唯一注意事项是在运行查询之前检查以确保远程数据库已关闭,否则会使尝试执行查询的数据库崩溃。

#2


0  

The "official" way, by which I assume you mean using the buttons on the ribbon, TMS, would be to use a Make Table Query. Of course, to update the linked data, you would have to run the make table query every time.

我认为你使用功能区上的按钮TMS的“官方”方式是使用Make Table Query。当然,要更新链接数据,您每次都必须运行make table查询。

#1


15  

You can do it this way:

你可以这样做:

SELECT [RemoteQueryname].* FROM [RemoteQueryname] IN 'C:\RemoteDatabase.mdb'

I have tested with databases locally on my machine and runs flawlessly. The only note I would like to point out is before running the query check to make sure the remote databse is closed or it will crash the one trying to do the query.

我在我的机器上本地测试了数据库并运行完美。我想指出的唯一注意事项是在运行查询之前检查以确保远程数据库已关闭,否则会使尝试执行查询的数据库崩溃。

#2


0  

The "official" way, by which I assume you mean using the buttons on the ribbon, TMS, would be to use a Make Table Query. Of course, to update the linked data, you would have to run the make table query every time.

我认为你使用功能区上的按钮TMS的“官方”方式是使用Make Table Query。当然,要更新链接数据,您每次都必须运行make table查询。