"DeleteDocument" Stored Procedure

Description:

This stored procedure deletes a single document item from the database. The input parameter is ItemID, the primary key for the record.

Definition:
    
   CREATE PROCEDURE Portal_DeleteDocument
   (
       @ItemID int
   )
   AS
   
   DELETE FROM Portal_Documents
   
   WHERE
       ItemID = @ItemID
        
Database Tables Used:

Documents:  Each record in the Documents table is a single item, as displayed by the Documents Portal Module. Since all Documents modules store their record in this table, each item contains a ModuleID to permit related items to be retrieved in a single query.

The primary key in this table is the ItemID identity field.