Home > Archive > MS SQL Server MSEQ > September 2005 > Re: How to call talbe/SP from Linked server with out database and









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: How to call talbe/SP from Linked server with out database and
Rajesha

2005-09-16, 3:24 am

Dear Kornelis,
Thanks for your responce.
I would like to say that, while configuring linked server there will be an
option to specify catelog(DatabaseName
). I think there is as chance, we can
get.
as of know below query

As you told with out user there is chance to work but , I tryed that I
getting error.

select * from [linkedserver].[database]..[TableName]

gives below error.

Server: Msg 7313, Level 16, State 1, Line 1
Invalid schema or catalog specified for provider 'MSDASQL'.
OLE DB error trace [Non-interface error: Invalid schema or catalog
specified for the provider.].

Thanks and Regards,
Rajesh


"Hugo Kornelis" wrote:

> On Wed, 14 Sep 2005 07:57:08 -0700, Rajesha wrote:
>
>
> Hi Rajesh,
>
> You can't leave out the databasename. A linked server might hold more
> than one database, so you have to specify that part.
>
> I believe that you can leave out the owner, but I'm not sure, and I
> can't test that right now. However, it is recommended that you always
> include the owner. This helps SQL Server find the object more quickly,
> and it helps reduce the number of recompiles.
>
> Best, Hugo
> --
>
> (Remove _NO_ and _SPAM_ to get my e-mail address)
>

Hugo Kornelis

2005-09-16, 8:24 pm

On Thu, 15 Sep 2005 22:05:01 -0700, Rajesha wrote:

>As you told with out user there is chance to work but , I tryed that I
>getting error.
>
>select * from [linkedserver].[database]..[TableName]
>
>gives below error.
>
>Server: Msg 7313, Level 16, State 1, Line 1
>Invalid schema or catalog specified for provider 'MSDASQL'.
>OLE DB error trace [Non-interface error: Invalid schema or catalog
>specified for the provider.].


Hi Rajesh,

Thanks for testing this, and posting back with the results.

So I guess that the answer to your original question is that this can't
be done - you must specify all four parts if you reference objects on a
linked server.

Best, Hugo
--

(Remove _NO_ and _SPAM_ to get my e-mail address)
Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com