Why it is not recommended to name a user defined store procedures with "sp_"?

 Posted by Rajnilari2015 on 3/17/2016 | Category: Sql Server Interview questions | Views: 260 | Points: 40
Answer:

They are system defined and mostly resides under the master db. So if we write a user defined stored procedure by the name "sp_" the query engine will first search the sp indside the master db and if not found then it will search in the current session db. This brings unnecessary round trip. Better to use some other naming convention as "usp_".


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response