Question : update statement doesnt work when using linked server

I have a update statement that is using a linked server method from within a SPROC

when i try and create the SPROC - it fails on first update
showing error message
Msg 7416, Level 16, State 1, Procedure sp_LeaverProcess, Line 7
Access to the remote server is denied because no login-mapping exists.

But when i do
select * from NEMESIS_LINKED.intranet.dbo.tblusers - the select works fine

Why is the update failing via the call but the select isnt

Code Snippet:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
CREATE PROCEDURE [dbo].[sp_LeaverProcess] 
AS
 
 
/* Set user status to Leaver for Intranet */
 
UPDATE NEMESIS_LINKED.intranet.dbo.tblusers
set status = 2, LeaveDate = GetDate()
 
FROM NEMESIS_LINKED.Intranet.dbo.tblUsers tblUsers_1 
JOIN dbo.view_SelectTodaysLeavers LEAV
  ON tblUsers_1.EmployeeID = LEAV.LoginID
 
/*Revoke Worksite login access */
 
update ws
set ws.login='N'
from MINOS_LINKED.docs.mhgroup.docusers ws, view_SelectTodaysLeavers TODL
where ws.userid = TODL.LoginID collate Latin1_General_CI_AS
Open in New Window Select All

Answer : update statement doesnt work when using linked server

i have
ive fixed this by changing the update statement and aliasing the table
Random Solutions  
 
programming4us programming4us