![]() |
Database »
Database »
SQL Server
Intermediate
License: The Code Project Open License (CPOL)
How to Config Linked Servers in a MinuteBy Kamran HazariHow to create Linked servers in a minute in an easy way |
SQL, SQL Server (SQL 2000, SQL 2005, SQL CE, SQL 2008), DBA
|
|
Advanced Search Add to IE Search |
|
|
|
||||||||||||||||
If you want to use a database from another Server Instance in your queries, you should do some workaround to reach your goal, or better say if you have distributed databases for an application and you want to use distributed queries here is the simple, easy solution.
Googling around would get you to this solution but it's important to know how much time you would spend on something. On this issue, it was so time consuming to find out how to really config the server to get it working, so now it's not.
This option is also available for SQL Server 2000. You should go to [Security]>[Linked Servers] tab under the connected SQL Server Instance.
SELECT * FROM [LLSS].[DBName].[Schema].[TableName]
SELECT * FROM [SERVER134].[CompanyDB].[dbo].[Employee]
[ZZZZZZZZZ]
[Server2005]
[ XXX.XXX.XXX.XXX\DDSS]
[192.168.100.134\Server2005]
[XX]
[sa]
[YY]
[MyS@P@ss ]
SELECT * FROM [XXX.XXX.XXX.XXX\DDSS].[DBName].[Schema].[TableName]
SELECT * FROM [192.168.100.134\SERVER2005].[ CompanyDB].[dbo].[Employee]
[XX]
[sa]
[YY]
[MyS@P@ss ]
General
News
Question
Answer
Joke
Rant
Admin
|
PermaLink |
Privacy |
Terms of Use
Last Updated: 29 Apr 2009 Editor: Deeksha Shenoy |
Copyright 2009 by Kamran Hazari Everything else Copyright © CodeProject, 1999-2009 Web22 | Advertise on the Code Project |