@@REMSERVER with linked servers
From: Peter Hyssett (peter@hyssett.fsnet.co.uk)
Date: 09/25/02
- Next message: Max Billingsley: "Re: HELP - no sa password "about to reinstall sql7""
- Previous message: Maher K. Al-Jendasi: "Database Users"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
From: "Peter Hyssett" <peter@hyssett.fsnet.co.uk> Date: Wed, 25 Sep 2002 04:55:42 -0700
Hi.
My system has multiple databases spread over multiple
linked servers. There is a requirement for a Stored
Procedure to call another Stored Procedure in another
database, which may or may not be on the same server. For
security I check @@NESTLEVEL, which is > 1 if the two SPs
are on the same server but = 1 if on linked servers.
According to BOL, @@REMSERVER would be non-null if the
call was from a remote server, but from a linked server it
comes up as NULL.
Is there an equivalent of @@REMSERVER (or some other
mechanism) which would identify the calling server when a
SP is called from a linked server?
Thanks in advance,
Peter.
- Next message: Max Billingsley: "Re: HELP - no sa password "about to reinstall sql7""
- Previous message: Maher K. Al-Jendasi: "Database Users"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|
|