I am developing an app where i have a local database in SQL Server Express. During work in local database, we need to execute a query on another SQL Server / live server and its return a value and with this value we execute a query in local server.
我正在开发一个应用程序,我在SQL Server Express中有一个本地数据库。在本地数据库中工作期间,我们需要在另一个SQL Server / live Server上执行一个查询,并返回一个值,然后在本地服务器中执行一个查询。
It is OK when executing this query against 2 or 3 queries, but i have around 5000 records on which I need to execute same process. I have done with above style but its take too much time.
对2或3个查询执行此查询是可以的,但是我有大约5000条记录需要执行相同的进程。我已经办过这种式样了,但要花很长时间。
I've found that we can run a query on multiple servers.
我发现我们可以在多个服务器上运行查询。
Can i run a query on SQL Server Express and server at same time and and run my whole queries in this style?
我是否可以在SQL Server Express和Server上同时运行查询并以这种方式运行整个查询?
I can run query from express to server only.
我只能从express到服务器运行查询。
1 个解决方案
#1
7
Yes you can. Setup the LinkServer on the SQL Express then just pass your query in the four part name format
是的,你可以。在SQL Express上设置LinkServer,然后以四部分名称格式传递查询
server . database . schema . object
服务器。数据库。模式。对象
example
例子
select * from LinkServer.mydatabase.dbo.Table
#1
7
Yes you can. Setup the LinkServer on the SQL Express then just pass your query in the four part name format
是的,你可以。在SQL Express上设置LinkServer,然后以四部分名称格式传递查询
server . database . schema . object
服务器。数据库。模式。对象
example
例子
select * from LinkServer.mydatabase.dbo.Table