Stored procedures are T-SQL that is compiled for later execution. They are able to accept parameters (these parameters can even be table types that you pass a table variable (see T-SQL Tip 16)). One of the benefits of stored procedures is everything that uses the SP does the same work, the same way. More likely to have metrics, and plan reuse. Since they accept parameters on input (and output), these parameters in execution plans get parameterized. This means that SQL Server doesn’t use your literal input value to form the plan but something generic. This makes the plans consistent for repeat runs, for better or worse though.