For example, have your application setup a schema to contain its version-specific database components. The schema will contain an immutable application version, such as its commit hash, in its name. This allows a given version of the application to only use its own set of sprocs and views. On deploy, run the SQL scripts to create the sprocs and views for that version.
You'll note that sprocs and views are not mutated under this strategy. This allows multiple versions to exist concurrently, which facilitates things like blue-green deploys.