Here is the SP i am using
--------------------------------------------
CREATE PROCEDURE dbo.sp_AddUpdateEmpTable
@EmpName nvarchar(50),
@EmpID int,
@returnEmpID int output
AS
BEGIN
If exists(select * from EmpTable where EmpID= @EmpID)
BEGIN
Update EmpTable
Set EmpName=@EmpName
Where EmpID = @EmpID
select @returnEmpID= @EmpID
END
Else
BEGIN
Insert into...