locked
Stored Proc - Calling a Remote Stored Proc RRS feed

  • Question

  • I am having trouble executing a stored procedure on a remote server. On my
    local server, I have a linked server setup as follows:
            Server1.abcd.myserver.com\SQLServer2005,1563

    This works fine on my local server:

    Select * From [Server1.abcd.myserver.com\SQLServer2005,1563].DatabaseName.dbo.TableName

    This does not work (Attempting to execute a remote stored proc named 'Data_Add':

    Exec [Server1.abcd.myserver.com\SQLServer2005,1563].DatabaseName.Data_Add 1,'Hello Moto'

    When I attempt to run the above, I get the following error:
    Could not locate entry in sysdatabases for database 'Server1.abcd.myserver.com\SQLServer2005,1563'.
            No entry found with that name. Make sure that the name is entered correctly.


    Could anyone shed some light on what I need to do to get this to work?

    Thanks - Amos.

    Thursday, August 24, 2006 2:34 PM

Answers

  • You're missing the 3 part of the 4-part name.

    [schema] could be dbo...

    Exec [Server1.abcd.myserver.com\SQLServer2005,1563].DatabaseName.[schema].Data_Add <para>

    Thursday, August 24, 2006 5:28 PM

All replies

  • You're missing the 3 part of the 4-part name.

    [schema] could be dbo...

    Exec [Server1.abcd.myserver.com\SQLServer2005,1563].DatabaseName.[schema].Data_Add <para>

    Thursday, August 24, 2006 5:28 PM
  • That was it - thank you!

     

    Thursday, August 24, 2006 5:54 PM