So if I have 3 stored procedures that act on a single table (or multiple tables for that matter), is it acceptable to combine them since they are related on some level and then using a switch or if statement to determine which "procedure" to actually run?
As a simplistic example, assume 3 stored procedures, one for creating a record (CreateRecord), one for updating a record (UpdateRecord) and one for deleting a record (DeleteRecord). Can I simply combine them into one procedure called something like RecordManager, or RecordController or whatever, and just have an additional parameter that says which of the 3 to execute?
I know it's actually possible to do this, but I'm asking is it a good idea? Has anyone ever seen this and said "whoever did this was awesome" or "*sigh* Why me?"
I'm always worried about the future and not being able to remember what something is for and I'm not sure if this would help or hurt that worry?