SQL Server Loopback Linked Server

Occasionally I run across companies that make use of linked servers. This can be a nasty little detail in a development environment to fully test database code. The solution is to create a loopback linked server so that code referencing a linked server will run as if it were running in the distributed production environment.

  1. Get a backup of the database on the other end of the linked server call.
  2. Restore the backup on your local SQL Server instance
  3. Run the code below to create the loopback linked server

EXEC sp_addlinkedserver @server = N’name_for_linked_server’,

@srvproduct = N’ ‘,

@provider = N’SQLNCLI’,

@datasrc = N’name_of_my_sqlserver_instance’,

@catalog = N’name_of_database’

 

 

Advertisement

BizTalk 2010 ESB 2.1 Portal Issue

Long live Google. I was having an issue with the ESB Portal (2.1) on a BizTalk 2010 machine. I found the fix at the following link.

http://www.businessprocessintegration.net/2009/03/espportal-and-a-network-related-or-instance-specific-error-occurred-while-establishing-a-connection-to-sql-server/

I was seeing this error when I would attempt to navigate to the Registry tab of the ESB Portal.

Exception information:

Exception type: SqlException

Exception message: A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 – No connection could be made because the target machine actively refused it.)

Request information:

Request URL: http://localhost/ESB.Portal/Lists/RegistrySummaryContainer.aspx

Request path: /ESB.Portal/Lists/RegistrySummaryContainer.aspx

The solution was to enabled TCPIP in the SQL Server Configuration Manager under SQL Server Network Configuration–>Protocols for MSSQLSERVER.

The same issue is addressed at this blog post and has an interesting comment.

I solved the problem the opposite way: I altered the connection string to remove “Network Library=dbmssocn”, thus eliminating the requirement to use TCP/IP.Richard

I did not try that solution, but it sounds plausible as well.

MSDN TV: Introduction to Analysis Services 2005

I watched this demo and it is really impressive how quicky analysis cubes can be created and consumed in SQL Server 2005. I haven’t had the opportunity to use analysis services with SQL Server 2000, so I can’t appreciate how much easier it is in 2005. However, the benefits of cubed data become apparent pretty quickly while watching this short demo.

MSDN TV: Introduction to Analysis Services 2005