Added more comments

Added comments to the stored procedures that describe what they do and
in some cases also which things they will affect.
Comments always contain information about who generated the code for the
procedure, when it was done, and in which environment.