Hi , I have a storedprocedure usp_InsertNewEmployee in a remote server. I have set up linked server and a synonym for the stored procedure.
I could execute the stored procedure as
Exec usp_InsertNewEmployee @EmployeeName = 'John'
But I need to execute the stored procedure as well as return the EmployeeId inserted to the new table which in an identity in that table . How can I use SCOPE_IDENTITY() to return this through open query.
Kindly provide an example.
Thanks
NK
↧