SQL Server error 8145: Is not a parameter for procedure
A named argument (@Name = value) doesn't match any parameter of the procedure. Usually a typo or a version mismatch between code and database.
- Error number
8145- Severity
- 16
- Category
- Names and objects
What it means
When arguments are passed by name, each name must match one of the procedure's declared parameters. Error 8145 names the argument that isn't recognized.
Common causes
- A misspelled parameter name.
- The parameter was renamed or removed in the deployed procedure, or hasn't been added yet.
- Calling the wrong procedure of a similar name.
How to fix it
-
List the procedure's real parameter names.
SELECT name FROM sys.parameters WHERE object_id = OBJECT_ID(N'dbo.SaveOrder') ORDER BY parameter_id;
-
Correct the argument name or deploy the matching procedure version.
Related errors
8144Too many arguments specified8146Procedure has no parameters2812Could not find stored procedure
More names and objects errors
208Invalid object name207Invalid column name4104Multi-part identifier not bound209Ambiguous column name2714There is already an object named3701Cannot drop, object not found3702Cannot drop database, currently in use5030Database couldn't be exclusively locked
The code and message text are from the Microsoft Database Engine events and errors reference. Browse the full SQL Server error list or search every database error.
Work on SQL Server in SQLly
A native SQL client for macOS, Windows and Linux with schema-aware IntelliSense, guardrails for risky statements and clear error messages, for SQL Server and the other databases you use.