I have a stored procedure which inserts new records from service to the database or update existing record. But I need to display true if it is inserted/updated successfully and if it fails, I need to display false in response.
so in my stored procedure call from EF
result = database.usp_sp_name(parameters);
if (result==0)
return true;
else
return false;
I tried the above code since I read in MSDN site that if successful transaction means, result will be 0. But even its inserting record or updating record, I am getting response as false.